0

I am getting really confused about configuring Sass config options. Basically I want to disable the line comments in the compiled css file. So I went in and created a sass.rb in the Initializers folder with the following line:

Rails.application.config.sass.line_comments = true

I then restart my apache server and check in Safari web developer, my css file still contains the comments like /* line## /path/to/css/file */ above every css statement. I then test it in Firefox and open Firebug, and I don't see those line comments there, which suggest inconsistent browser behavior.

So I go back to my initializer sass.rb file and turn on line_comments, restart the web server and try again, this time I get the exact same result as before, nothing's changed, that basically tells me either that's specific to the browsers, there's a problem with the setting scope/syntax, or there's a caching issue (I'm working in development, so there shouldn't be any caching, right?). I'd really appreciate if someone can provide some insight on this. Thanks.

EDIT: The proposed solution to make a change to the sass file(s) didn't solve anything so I doubt it is the same problem.

Note: I am using sass with rails and I am getting separate css files for each of my sass files, which doesn't seem very right...

JackyJohnson
  • 3,106
  • 3
  • 28
  • 35
  • Related: http://stackoverflow.com/questions/17976140/false-positive-undefined-variable-error-when-compiling-scss – cimmanon Jan 13 '15 at 17:03

1 Answers1

0

The problem was a combination of needing to set config.assets.debug to false for development, setting config.assets.compress to true, and probably a better understanding of sass compilation.

JackyJohnson
  • 3,106
  • 3
  • 28
  • 35