Sass is a popular CSS preprocessor that adds special features (e.g., variables, nested rules) to facilitate the maintenance of large sets of CSS rules. If youβre curious about what Sass is and why it might be useful for styling your static site, the following links may be of interest:
It currently uses grass, a Rust implementation of Sass roughly equivalent with dart-sass.
Zola processes any files with the sass
or scss
extension in the sass
folder, and places the processed output into a css
file with the same folder
structure and base name into the public
folder:
Files with a leading underscore in the name are not placed into the public
folder, but can still be used as @import
dependencies. For more information, see the βPartialsβ section of
Sass Basics.
Files with the scss
extension use βSassy CSSβ syntax,
while files with the sass
extension use the βindentedβ syntax: https://sass-lang.com/documentation/syntax.
Zola will return an error if scss
and sass
files with the same
base name exist in the same folder to avoid confusion β see the example above.