Adds clean-css and UnCSS support to brunch.
In this case we have two processes excuted on the same. I have not seen a possibility to queue two plugins wchich will do the same, so I queue these processes in one plugin.
Install the plugin via npm with
npm install --save clean-css-uncss-brunch
Or add it to package.json dependencies:
To specify options, use
config.plugins.cleanuncss object in Brunch config file.
You can use all standard options for clean-css and UnCSS.
plugins: cleanuncss: uncss: options: csspath: '../styles' htmlroot: 'build' files: ['index.html', 'about.html'] cleancss: keepSpecialComments: 0 removeEmpty: true
Plugin is created to use both clean-css and UnCSS. Technically, UnCSS is base for both processes - if you don't set options for UnCSS, nothing will happen (actually, you will see error in your console/terminal, but no data will be processed). If you want, you can to not set clean-css options. But then you'll have just uncss-brunch-like plugin.