-
Notifications
You must be signed in to change notification settings - Fork 0
API options
Gabriel Scatolin edited this page Sep 25, 2023
·
2 revisions
You can specify compilation options under the CSSCompilerOptions
parameter, which:
-
bool Pretty
produces an pretty, formatted and indented output. Example:
main {
position: relative;
div + nav {
color: red;
}
}
Pretty:
main div + nav {
color: red;
}
main {
position: relative;
}
Non-pretty:
main div+nav{color:red}main{position:relative}
-
bool UseVarShortcut
specifies if the compiler should rewrite--variable
tovar(--variable)
in the value context, example:
:root {
--red: #FF1100;
}
div {
color: --red;
}
Will be rewrited to:
div {
color: var(--red);
}
And it will NOT rewrite if the variable is inside an string:
div {
color: --red;
background: url('--red');
}
// becomes:
div {
color: var(--red);
background: url('--red');
}