SASS variables inter-files scope -
in order use
@include box-shadow(0 0 10px black);
you have include "library":
@import "compass/css3";
later in file, including other scss:
@import "sidebar/main";
and in sidebar/_main.scss, when call same:
@include box-shadow(0 0 10px black);
compass breaks error:
< ... undefined mixin 'box-shadow'.>
does mean i'll have abstract libraries in own library file, , include file in each , every other scss???
rename sidebar/main.scss sidebar/_main.scss - no other code changes needed.
this instructs sass compiler not compile sidebar/main.scss file separate css file, include in main scss file.
the process works this:
sass compiles main scss file inclusions , generates css (no errors here, since compass included @ top) sass compiles other scss files don't begin _, since these don't have compass included, throws error.
Comments
Post a Comment