Ruby on Rails CoffeeScript failing

Damien picture Damien · Nov 28, 2011 · Viewed 7.5k times · Source

I have this error which is making it impossible to load my app

no such file to load -- coffee_script
  (in /Users/damien/projects/easyJobs/app/assets/javascripts/jobs.js.coffee)
Extracted source (around line #10):

7:  /[if lt IE 8]
8:     = stylesheet_link_tag 'ie.css', :media => 'screen, projection'
9:     = stylesheet_link_tag :application
10:     = javascript_include_tag :application
11:     = csrf_meta_tag
12: 
13:   %body

The files are all there but doesnt look like its seeing them for a reason beyond me :/ If anyone knows why this error may be happening let me know would be very much appreciated.

Damien

Answer

fuzzyalej picture fuzzyalej · Dec 1, 2011

Try adding to your `Gemfile:

group :assets do
  gem 'coffee-rails'
end

More info here