sass - False positive "undefined variable" error when compiling SCSS -


getting error message when compiling scss using ruby compass gem.

run: /var/lib/gems/1.8/gems/compass-0.12.2/bin/compass compile out: unchanged sass/partial/grid.scss out:     error sass/partial/catalog.scss (line 5: undefined variable: "$paragraphfont".) out:    create css/generated/partial/catalog.css  out:    create css/generated/partial/base.css  out: overwrite css/generated/screen.css 

my screen.scss imports partials this:

@import "partial/base"; @import "partial/catalog"; 

in base partial have $paragraphfont defined.

$paragraphfont: 'lucida sans', arial; $regularfontsize: 14px; 

and in catalog.scss use it:

.product-view #price-block {     p {         font-weight: normal;         font-family: $paragraphfont;         ....     } } 

weird thing css gets compiled fine, , $paragraphfont populated correctly. don't know why compiler complaining @ me error.

you're generating files don't need generated.

  • screen.scss -> screen.css
  • base.scss -> base.css
  • catalog.scss -> catalog.css

the catalog file being compiled on own. since not importing base.scss, variables not set. screen.scss file generates expect because importing of necessary information.

what want rename partials begin underscore prevent them being compiled on own:

  • screen.scss -> screen.css
  • _base.scss (not compiled)
  • _catalog.scss (not compiled)

Comments

Popular posts from this blog

c++ - Creating new partition disk winapi -

Android Prevent Bluetooth Pairing Dialog -

VBA function to include CDATA -