LibraryActive

UnoCSS Vite Plugin

Vite plugin for UnoCSS, shipped with the unocss package.

Open source page

Product features

Product features

Blocklist ​

Content Sources ​

Edit classes in DevTools

Import virtual:unocss-devtools to detect class changes via MutationObserver.

dist-chunk mode (experimental)

Generates a CSS sheet for each code chunk on build.

Extracting ​

Extracting from Build Tools Pipeline ​

Extracting from Filesystem ​

Extracting from Inline Text ​

global mode

Default mode; import virtual:uno.css in entry point, with HMR support.

Limitations ​

Matcher Types ​

Messages ​

per-module mode (experimental)

Generates a CSS sheet for each module, can be scoped.

Safelist ​

shadow-dom mode

Inlines generated CSS into Shadow DOM via @unocss-placeholder.

Static List Combinations ​

Variant Awareness ​

vue-scoped mode

Injects generated CSS into Vue SFC <style scoped> blocks.