title: Running a CoffeeScript Class on document.ready
body: <p>i have </p>
  
  <pre><code>class Main
     test:-&gt;
        alert "yay!"
  </code></pre>
  
  <p>in coffeescript, and i want to run that inside my index.html</p>
  
  <pre><code>&lt;script&gt;
      $(function(){
          //and obv Main.test(); doesn't work
      });
  &lt;/script&gt;
  </code></pre>
  
  <p>there is a note of this on the website, it says it wouldn't work. But I couldn't find how to make it work. any ideas? i need to find out what coffeescript closure wrapper is.</p>
  
  <p>or does coffeescript execute after document.ready anyway?</p>
  
  <p>thx!</p>