-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathvite-ui.config.js
42 lines (41 loc) · 1005 Bytes
/
vite-ui.config.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
import { defineConfig } from "vite";
import { viteSingleFile } from "vite-plugin-singlefile";
import vue from "@vitejs/plugin-vue";
import { fileURLToPath, URL } from "url";
import svgLoader from "vite-svg-loader";
export default defineConfig({
root: "src/ui",
publicDir: "../../public",
plugins: [vue(), viteSingleFile(), svgLoader()],
resolve: {
alias: {
"@": fileURLToPath(new URL("./src", import.meta.url)),
},
},
css: {
preprocessorOptions: {
scss: {
additionalData: `@import "@/ui/assets/style/index.scss";`,
},
},
},
build: {
target: "esnext",
assetsInlineLimit: Infinity,
chunkSizeWarningLimit: 100000000,
cssCodeSplit: false,
brotliSize: false,
emptyOutDir: false,
outDir: "../../dist",
sourcemap: true,
rollupOptions: {
inlineDynamicImports: true,
output: {
manualChunks: () => "everything.js",
},
input: {
index: "src/ui/index.html",
},
},
},
});