title: How can I load my own js module with goog.provide and goog.require?
body: <p>We are trying to switch the packaging for our project from dojo to google closure, but we haven't had any luck so far. Here is a simple example that illustrates what we are trying to accomplish:</p>
  
  <pre><code>
  &lt;html xmlns="http://www.w3.org/1999/xhtml">
      &lt;head>
          &lt;script type="text/javascript" src="runtime/src/core/lib/goog-rev26/base.js">&lt;/script>
          &lt;script>
              goog.require("foo.bar");
              function main() {foo.bar.echo("hello world")}
          &lt;/script>
      &lt;/head>
  &lt;body onload="main()">
  &lt;/body>
  &lt;/html>
  </code>
  </pre>
  
  <p>Then in <code>/foo/bar.js</code> I have:</p>
  
  <pre><code>
  goog.provide("foo.bar");
  foo.bar.echo = function(s) {console.debug(s);}
  </code></pre>
  
  <p>The errors I receive in firebug are as follows:</p>
  
  <pre>
  goog.require could not find: foo.bar
  foo is not defined
  </pre>
  
  <p>When I look in the Net tab, there isn't an http request out to fetch a file - I was expecting the closure library to generate a script tag to fetch <code>bar.js</code>.</p>
  
  <p>help! ;)</p>