title: Javascript call nested function
body: <p>I have the following piece of code:</p>
  
  <pre><code>function initValidation()
  {
      // irrelevant code here
      function validate(_block){
          // code here
      }
  }
  </code></pre>
  
  <p>Is there any way I can call the <code>validate()</code> function outside the <code>initValidation()</code> function? I've tried calling <code>validate()</code> but I think it's only visible inside the parent function.</p>