zeokku / vite-plugin-vue-css-modules

✨ Ultimate solution for using CSS modules without any hassle.
17 stars 0 forks source link

Strip unused classnames #6

Open Lutymane opened 1 year ago

Lutymane commented 1 year ago

Since template and script processing is done first, it's easy to determine which classes are used.

Lutymane commented 1 year ago

Use config() hook to include custom PostCSS plugin, which would strip unused class selectors https://github.com/postcss/postcss/blob/main/docs/writing-a-plugin.md