fix: speed up wails dev gui startup
This commit is contained in:
+25
@@ -125,3 +125,28 @@
|
||||
- `npm install` 仍报告 3 个 moderate audit findings。
|
||||
- 前端构建仍提示 Browserslist 数据过期。
|
||||
- Vite 仍提示生产 chunk 大于 500 kB。
|
||||
|
||||
### 修复 dev.bat GUI 启动等待过长
|
||||
|
||||
- 任务:用户反馈 `dev.bat` 仍然看不到 GUI 后,继续排查 Windows dev 启动链路。
|
||||
- 发现:
|
||||
- 清理旧的无窗口 `bin/cmbone.exe` 残留进程后,`dev.bat` 可以进入 `windows:run`。
|
||||
- GUI 不是完全无法创建,而是开发启动链路先执行 `vue-tsc && vite build --minify false --mode development`,窗口要等该步骤完成后才出现。
|
||||
- 窗口枚举确认主窗口可见,标题为 `main`,第二窗口保持隐藏。
|
||||
- 结果:
|
||||
- `frontend/package.json` 新增 `typecheck` 脚本。
|
||||
- `build:dev` 改为只执行快速 Vite dev 构建,避免开发启动时被 `vue-tsc` 长时间阻塞。
|
||||
- `npm run build` 仍保留 `vue-tsc`,提交前完整质量门禁不变。
|
||||
- 修复 `App.vue` 的 `ConfigProvider` 导入和第二窗口 OCR 卡片的 `TransitionGroup` key 警告。
|
||||
- 验证:
|
||||
- `go test ./...` 通过。
|
||||
- `cd frontend && npm run typecheck` 通过。
|
||||
- `cd frontend && npm run build:dev` 通过,Vite dev 构建约 1 秒完成。
|
||||
- `cd frontend && npm run build` 通过。
|
||||
- `go build -o bin\cmbone.exe .` 通过。
|
||||
- `cmd /c build.bat` 通过。
|
||||
- `dev.bat` 烟测通过,进入 `windows:run` 后拉起 `bin/cmbone.exe`,窗口枚举显示主窗口 `main` 可见,第二窗口 `second` 保持隐藏。
|
||||
- 非阻塞警告:
|
||||
- `cmd /c build.bat` 仍提示 `wails3 build` 是 `wails3 task` 的 alias。
|
||||
- `npm install` 仍报告 3 个 moderate audit findings。
|
||||
- 前端构建仍提示 Browserslist 数据过期和 chunk 大小警告。
|
||||
|
||||
Reference in New Issue
Block a user