Adds support for the Sass CSS pre-processor to DocPad using node-sass
.sass syntax is not supported by node-sass, so it is not supported by this plugin.
npm install --save docpad-plugin-nodesass
outputStyle is a
String to determine how the final CSS should be rendered. Its value should be one of
'compact' are not currently supported by libsass.
imagePath is a
String that represents the public image path. When using the
image-url() function in a stylesheet, this path will be prepended to the path you supply. eg. Given an
background-image: image-url('image.png') will compile to
precision is a
Number that will be used to determine how many digits after the decimal will be allowed. For instance, if you had a decimal number of
1.23456789 and a precision of
5, the result will be
1.23457 in the final CSS.
includePaths is an
Array of path
Strings to look for any
@imported files. It is recommended that you use this option if you are using the
data option and have any
@import directives, as otherwise [libsass] may not find your depended-on files.
normal will print comments in the output css that indicates the source file name and line number.
map will produce a sourcemap. Using either of these options instead of
none will prevent you from being able to run any other process on the file (e.g.
debugInfo requires passing an actual file instead of
By default we prevent any SCSS stylesheets that filename starts with underscore character from being rendered and written to the output directory. This is to follow SCSS convention that such files are just intended to be included inside out stylesheets, and that they are not meant to be rendered by themselves. If you really want to, you can render the underscore stylesheets by setting the
renderUnderscoreStylesheets option to
true in your plugin's configuration.