问题
I just moved my Rails app to a production server through git and none of my JavaScript is working. I ran rake assets:precompile
and nothing. My Rails production log and my nginx log show no errors. Inside public/assets I see application-###.js
. Does anyone have any ideas or where else I can look?
My production.rb log looks like so:
Connecting to database specified by database.yml
Started GET "/" for 99.179.144.13 at 2013-04-03 04:13:42 +0000
Processing by StaticPagesController#index as HTML
Rendered static_pages/index.html.erb within layouts/application (3.5ms)
Rendered layouts/_menu.html.erb (2.6ms)
Rendered layouts/_sidebar_left.html.erb (9.5ms)
Rendered layouts/_sidebar_right.html.erb (3.6ms)
Completed 200 OK in 118ms (Views: 105.3ms | ActiveRecord: 12.4ms)
来源:https://stackoverflow.com/questions/15778847/javascript-not-working-in-rails-app-in-production