With Rollup
Start by installing the Rollup plugin as a dev dependency.
1
npm i -D rollup-plugin-purgecss
Copied!
1
import { rollup } from 'rollup'
2
import purgecss from 'rollup-plugin-purgecss'
3
4
rollup({
5
entry: 'main.js',
6
plugins: [
7
purgecss({
8
content: ['index.html']
9
})
10
]
11
})
Copied!
Last modified 3yr ago
Copy link