github.io/postcss.config.js

13 lines
349 B
JavaScript
Raw Normal View History

const purgecss = require('@fullhuman/postcss-purgecss')({
content: [ './hugo_stats.json' ],
defaultExtractor: (content) => {
let els = JSON.parse(content).htmlElements
return els.tags.concat(els.classes, els.ids)
}
})
module.exports = {
plugins: [
purgecss,
// ...(process.env.NODE_ENV === 'production' ? [ ] : [])
]
}