File tree Expand file tree Collapse file tree 2 files changed +18
-7
lines changed
Expand file tree Collapse file tree 2 files changed +18
-7
lines changed Original file line number Diff line number Diff line change 11{
22 "name" : " @bufferhead/nightowl" ,
3- "version" : " 0.0.7 " ,
3+ "version" : " 0.0.8 " ,
44 "type" : " module" ,
55 "scripts" : {
66 "dev" : " vite" ,
1212 "postcss" : " ^8.4.31" ,
1313 "postcss-nesting" : " ^12.0.1" ,
1414 "typescript" : " ^5.2.2" ,
15- "vite" : " ^5.0.0"
16- }
15+ "vite" : " ^5.0.0" ,
16+ "vite-plugin-lib-inject-css" : " ^1.3.0"
17+ },
18+ "sideEffects" : [
19+ " **/*.css"
20+ ]
21+
1722}
Original file line number Diff line number Diff line change 11// vite.config.js
22import { resolve } from 'path'
33import { defineConfig } from 'vite'
4+ import { libInjectCss } from 'vite-plugin-lib-inject-css' ;
45
56export default defineConfig ( {
7+ plugins : [
8+ libInjectCss ( ) , // For a simple usage
9+ ] ,
610 build : {
711 lib : {
812 // Could also be a dictionary or array of multiple entry points
@@ -11,8 +15,10 @@ export default defineConfig({
1115 // the proper extensions will be added
1216 fileName : 'nightowl' ,
1317 } ,
14- rollupOptions : {
15-
16- } ,
17- } ,
18+ rollupOption : {
19+ output : {
20+ intro : 'import "./style.css";' ,
21+ }
22+ }
23+ }
1824} )
You can’t perform that action at this time.
0 commit comments