Reputation: 12605
Just playing around with Rails 3.1 at the moment, and one issue I'm having is wondering where to place SCSS variables and mixins.
What I mean is, what with scss stylesheets being separated by controller, I'm wondering where to put SCSS variables so that I won't need to redeclare them in every separate stylesheet. I'm guessing there's a standard place?
Cheers
Upvotes: 2
Views: 310
Reputation: 3062
I recommend a "_base" partial. Put all your stuff in there then include it in application.css.scss and include everything in there that way it inherits from "_base"
Make sure you use SASS @import "*/*";
for the includes and not sprockets, as sprockets doesn't carry over the variables since it's not the SASS engine.
Upvotes: 1
Reputation: 6516
I would recommend looking at twitter's bootstrap and see how it's organized
Upvotes: 0