I ran rake assets:precompile
by mistake on development, and Rails stopped loading the assets on development. I only get application.js
and application.css
loaded.
application.js:
//= require jquery
//= require jquery_ujs
//= require_tree .
application.css:
*= require_self
*= require_tree .
Using Rails 3.2.2
The asset pipeline is implemented by the sprockets-rails gem, and is enabled by default. You can disable it while creating a new application by passing the --skip-asset-pipeline option. The sassc-rails gem is automatically used for CSS compression if included in the Gemfile and no config. assets.
The Rails asset pipeline provides an assets:precompile rake task to allow assets to be compiled and cached up front rather than compiled every time the app boots. There are two ways you can use the asset pipeline on Heroku. Compiling assets locally. Compiling assets during slug compilation.
asset_path(source, options = {}) public. This is the entry point for all assets. When using the asset pipeline (i.e. sprockets and sprockets-rails), the behavior is “enhanced”. You can bypass the asset pipeline by passing in skip_pipeline: true to the options. All other asset *_path helpers delegate through this method ...
Try deleting the compiled assets from your local development environment:
rm -rf public/assets
Edit:
In addition, make sure to set config.assets.compress = false
and config.assets.debug = true
in your development.rb
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With