问题
I want to manually precompile some assets in my dev environment (to check the content of the compiled js and css files) from the command line.
I am running
RAILS_ENV=development bundle exec rake assets:precompile
but my js and css are not compiled in the public/assets folder, only the images are. Any idea why that may be happening?
回答1:
Try adding this to your config/environments/production.rb
:
config.assets.precompile += %w( *.css *.js )
来源:https://stackoverflow.com/questions/10081832/how-do-i-precompile-assets-in-rails-in-development-environment