How to make Rails 3.1 use SASS (Over SCSS) as the default?

krainboltgreene picture krainboltgreene · May 15, 2011 · Viewed 16.5k times · Source

Having a hard time figuring out how to make SASS, not SCSS, as the default for stylesheets.

I've tried making a sass_config.rb file with this:

Sass::Plugin.options[:syntax] = :sass
Sass::Plugin.options[:style] = :compressed

I've also tried adding that to the environment.rb file. Either way I get this error:

.../config/environment.rb:7:in `<top (required)>': 
  uninitialized constant Sass::Plugin (NameError)

Answer

Kevin picture Kevin · Jun 11, 2011

For rails 3.1.rc4, you could set the config:

config.sass.preferred_syntax = :sass

in the application.rb file