naive-ui/build/vite-plugin-css-render.js
Jiwen Bai 8131aa343c chore: migrate to Vite2 (#347)
* chore: migrate to vite2

* styles: remove unsed code

* chore: update package.json

Co-authored-by: Volankey <jiwen.bai@tusimple.ai>
2021-01-12 13:17:26 +08:00

16 lines
276 B
JavaScript

const cleanCssr = require('./utils/clean-cssr')
module.exports = () => {
return {
name: 'css-render-vite',
transform (src, id) {
if (id.endsWith('.cssr.js')) {
return {
code: cleanCssr(src),
map: null
}
}
}
}
}