-
Notifications
You must be signed in to change notification settings - Fork 20
/
vite.config.mts
84 lines (77 loc) · 2.02 KB
/
vite.config.mts
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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
/// <reference types="vitest" />
import { resolve } from "node:path";
import { defineConfig } from "vite";
import vue from "@vitejs/plugin-vue";
import { htmlTemplate } from "./plugins/html_template";
export default defineConfig({
resolve: {
alias: [{ find: "@", replacement: "/src" }],
},
plugins: [
vue(),
htmlTemplate({
APP_VERSION: `${process.env.npm_package_version}`,
}),
],
base: "./",
build: {
rollupOptions: {
input: {
main: resolve(__dirname, "index.html"),
prompt: resolve(__dirname, "prompt.html"),
"layout-manager": resolve(__dirname, "layout-manager.html"),
},
},
outDir: resolve(__dirname, "dist"),
chunkSizeWarningLimit: 5000000,
},
server: {
port: 5173,
strictPort: true,
},
test: {
dir: "./src/tests",
globals: true,
environment: "jsdom",
coverage: {
exclude: [
"docs",
"plugins",
"scripts",
"dist",
// テストコード
"src/tests",
// 設定ファイル
"vite.config.mts",
"webpack.config.cjs",
".*.*",
"**/*.d.ts",
"**/*.vue",
// 定義/設定
"src/common/ipc/**/*.ts",
"src/common/control/**/*.ts",
"src/common/i18n/**/*.ts",
"src/command/common/preload.ts",
// IPC
"src/renderer/ipc/api.ts",
"src/renderer/ipc/bridge.ts",
"src/renderer/ipc/preload.ts",
"src/renderer/ipc/web.ts",
"src/renderer/ipc/setup.ts",
// UI/Window
"src/background/index.ts",
"src/background/window/ipc.ts",
"src/background/window/main.ts",
"src/background/window/menu.ts",
"src/background/window/prompt.ts",
"src/background/window/layout.ts",
"src/renderer/index.ts",
"src/renderer/assets/icons.ts",
"src/renderer/devices/audio.ts",
"src/renderer/devices/hotkey.ts",
// コマンド
"src/command/usi-csa-bridge/index.ts",
],
},
},
});