lacroixdesign / node-neat

A node-sass port of Bourbon Neat.
http://lacroixdesign.github.io/node-neat
Other
65 stars 9 forks source link

Override default variables #3

Closed mxgz closed 10 years ago

mxgz commented 10 years ago

I'm using libsass with grunt-sass and could only change default neat variables before import neat library.

Example which not works:

@import "neat";

$grid-columns: 9;
$column: 100%;
$gutter: 20%;
$max-width: 1050px;

$visual-grid: true;
$visual-grid-index: front;
$visual-grid-opacity: 0.6;
$visual-grid-color: #eee;

Example which works:

$grid-columns: 9;
$column: 100%;
$gutter: 20%;
$max-width: 1050px;

$visual-grid: true;
$visual-grid-index: front;
$visual-grid-opacity: 0.6;
$visual-grid-color: #eee;

@import "neat";
iamlacroix commented 10 years ago

Hey mxgz!

Neat uses the !default flag when declaring all of those variables, so that is the intended result. Neat will only assign its default value to each of those variables if you haven't already defined your own value, so you'll need to do so before loading Neat.

See the original Neat's Getting Started guide for details, as well as the Sass documentation for !default for additional info on !default.

mxgz commented 10 years ago

Oh my fault, thanks for your explanation!