title: How to fix "foo is not defined" error reported by JSlint?
body: <blockquote>
    <p><strong>Possible Duplicate:</strong><br>
    <a href="https://stackoverflow.com/questions/9621162/jslint-was-used-before-it-was-defined">JSLint: was used before it was defined</a>  </p>
  </blockquote>
  
  
  
  <p>I run <code>JSlint</code> and saw errors like that:</p>
  
  <pre>'foo' is not defined.
  var x = foo();</pre>
  
  <p><code>foo</code> is a function defined in another <code>JavaScript</code> file <code>foo.js</code>. As I understand there is no "import / require" directives in <code>JavaScript</code> to reference the <code>foo</code> function defined in another source file.</p>
  
  <p>How can I fix this error repoted by <code>JSlint</code>? </p>