-
Notifications
You must be signed in to change notification settings - Fork 0
/
vite.config.js
46 lines (45 loc) · 1.16 KB
/
vite.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
43
44
45
46
import rollupOptions, {plugins, NAME} from "./rollup/rollup.config";
import {resolve} from "node:path";
//
export const __dirname = resolve(import.meta.dirname, "./");
export default {
plugins,
server: {
port: 5173,
open: false,
origin: "http://localhost:5173",
},
build: {
chunkSizeWarningLimit: 1600,
assetsInlineLimit: 1024 * 1024,
minify: "terser",
sourcemap: 'hidden',
target: "esnext",
name: NAME,
lib: {
formats: ["es"],
entry: resolve(__dirname, './src/main/index.ts'),
name: NAME,
fileName: NAME,
},
rollupOptions
},
optimizeDeps: {
include: [
"./node_modules/**/*.mjs",
"./node_modules/**/*.js",
"./node_modules/**/*.ts",
"./src/**/*.mjs",
"./src/**/*.js",
"./src/**/*.ts",
"./src/*.mjs",
"./src/*.js",
"./src/*.ts",
"./test/*.mjs",
"./test/*.js",
"./test/*.ts"
],
entries: [resolve(__dirname, './src/index.ts'),],
force: true
}
};