title: Get rails view helper methods inside coffeescript
body: <p>I have a view helper, let say (for simplicity's sake)</p>
  
  <pre><code>def call_alert
    return "alert 'this should appear'"
  end
  </code></pre>
  
  <p>Then I have a coffeescript file <strong>some_test_page.js.coffee</strong> which renders for an action which is called via ajax.
  Inside this <strong>some_test_page.js.coffee</strong> I have:</p>
  
  <pre><code>&lt;%= call_alert %&gt;
  </code></pre>
  
  <p>When I do an ajax call to <strong>/some_test_page</strong>, I usually would expect to get a response with the compiled javascript from the coffeescript file and an alert would occur. However, it seems the view helper I tried to use cannot be accessed.</p>
  
  <p>If I put a simple</p>
  
  <pre><code>alert 'this should appear'
  </code></pre>
  
  <p>inside my some_test_page.js.coffee file it works fine.</p>
  
  <p>I feel like this should be ok, but maybe I'm doing something counter-convention or stupid?</p>
  
  <p>How can I get the view helpers from application_helper.rb inside my coffeescript view files?</p>