feat: 重构录制逻辑,添加错误处理,更新消息常量,使用 terser 进行构建压缩

This commit is contained in:
雨霖铃
2026-02-03 23:42:28 +08:00
parent 37f8ef9c2b
commit e6f41032c8
8 changed files with 123 additions and 49 deletions
+14
View File
@@ -31,4 +31,18 @@ export default defineConfig({
128: 'favicon.ico',
},
},
vite: () => ({
build: {
// 1. 切换压缩器为 terser
minify: 'terser',
// 2. 配置 terser 强制转义所有非 ASCII 字符
terserOptions: {
format: {
ascii_only: true,
comments: false, // 去掉注释,防止注释里有乱码
},
},
},
}),
});