rails 3.1 updating css issues
I just updated from 3.0.8 to rails 3.1 rc1. However,the css in my site is clearly not being accessed beacuse my site has no design anymore. I though i could fix it by creating an assets folder and placing my stylesheets and js inside the app/assets folder but that hasn't worked.
I also commented this line out in my config/environments/development.rb
file
#config.action_view.debug_rjs 开发者_开发百科 = true
and I added this file to my config/application.rb
file
config.assets.enabled = true
Here is what my gemfile looks like:
source 'http://rubygems.org'
gem 'rails', '3.1.0.rc1'
gem 'devise'
gem 'jquery-rails'
gem 'omniauth'
gem 'rails3-generators'
gem 'rails_admin', :git => 'git://github.com/sferik/rails_admin.git'
gem 'sass-rails'
group :development do
gem 'sqlite3-ruby'
end
What am I doing wrong?
P.S. my images are also not showing up
Your app/assets
directory should look like this:
app/
assets/
images/
pancakes.png
...
javascripts/
application.js
...
stylesheets/
application.css
...
There is a guide to the new asset pipeline. You might have to fix some paths as well.
精彩评论