pug-plugin-css-modules
A Pug plugin to use CSS Modules.
Usage
Templates
style include:scss ./styles-pug.scss span span.base span.background
Code above will be processed into:
Firstly it will search css-classes into in local template, then into global map, if nothing matches css-class will be handled as global one.
Configuration
You can pass all the same options that available for CSS Modules into plugin, example:
let PugPluginCSSModules = default;let compile = pug;fs;
Notes
Plugin applies after filters so you feel free to use any css-preprocessors (like scss, less).