Carry Sass variables through the Assets Pipeline, Rails 3.1 rc1 Carry Sass variables through the Assets Pipeline, Rails 3.1 rc1 ruby-on-rails ruby-on-rails

Carry Sass variables through the Assets Pipeline, Rails 3.1 rc1


Sass supports Partials. That way you can include your separate configuration in __configuration.sass_ and reference it with

@import "configuration";

from your main sass-file.


Unfortunately I found out that SASS variables are be page specific.

If you want to carry your variables across all files, remove the *= require_tree . line from your application.css.scss file and replace it with the @import "layout.css.scss"; directive to manually import each sass file.

Yes you have to @import each file