npm install poi-preset-purifycssUse purify-css to remove unused CSS. See egoist/poi#253
``bash`
yarn add poi-preset-purifycss --dev
This preset will add PurifyCSSPlugin with purifycss-webpack for you:
By default it will scan all *.vue files for markup to determine what CSS classes you are using.
`js`
// poi.config.js
module.exports = {
presets: [
require('poi-preset-purifycss')()
]
}
Then it will reduce CSS code when you run poi build.
It accepts the same options as which in purifycss-webpack:
`js``
require('poi-preset-purifycss')({ minimize: true, paths: '*/.html' })
MIT © morrislaptop