create an empty bootstrap.less inside your project that will import variables.less, then customize variables you want, then import bootstrap.less.
Less @import
is an implicit « import once » (like the php require_once
) , so the @import variables.less
present in official bootstrap.less file will not reload the default variables.
This way allows you to update easier the twitter bootstrap library when you need.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 |
@import "../twitter-bootstrap/less/variables.less" @import "variables.less" // customize (or not) variables @import "../twitter-bootstrap/less/mixins.less" @import "mixins.less" // in that file already imported .less will be not re-imported // unless you explicitely ask it when compiling @import "../twitter-bootstrap/less/bootstrap.less" // Alternative : // instead of importing native bootstrap.less // you can only take some importation //== Custom // //## add your own specific rules here |