title: Is $(document).ready() called after loading all script files in the body?
body: <p>Is $(document).ready() called after loading script js files in the body ?</p>
  
  <p>If I put $(document).ready() in the head in script element which take a callback function that using a functions declared in a file which its script element loaded in the body like that :</p>
  
  <pre><code>&lt;!DOCTYPE HTML&gt;
  &lt;html&gt;
  &lt;script src="jquery.js" type="text/javascript"&gt;&lt;/script&gt;
  &lt;script&gt;
  $(function(){
  hello();
  })
  &lt;/script&gt;
  &lt;head&gt;
  &lt;/head&gt;
  &lt;body&gt;
  
  &lt;script src="http://somewhere/helloFuncDeclaration.js" type="text/javascript"&gt;&lt;/script&gt;
  
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>Is it a right way to do that and guarantee that the helloFuncDeclaration.js will be loaded before calling the function hello() ?</p>