新增: AI 助手 Markdown 渲染+打字机流式+桌面 Rust 代理修复 CORS

This commit is contained in:
lxy
2026-08-24 02:13:15 +08:00
parent 7f08f654d9
commit db3b2c24b7
8 changed files with 463 additions and 167 deletions
+13 -3
View File
@@ -6,9 +6,19 @@ export default defineConfig(({ mode }) => ({
build: {
chunkSizeWarningLimit: 800,
},
// npm run devmode=web)→ 浏览器模式,端口 8080
// npm run dev:web(mode=web)→ 浏览器模式,端口 8080
// npm run tauri:dev → 默认 mode,端口 5173
server: mode === 'web'
? { host: '127.0.0.1', port: 8080, open: true }
: { host: '127.0.0.1', port: 5173, strictPort: true },
? {
host: '127.0.0.1', port: 8080, open: true,
// 与 tauri dev 共存时防止 watch Cargo 产物(EBUSY 崩 watcher
watch: { ignored: ['**/src-tauri/target/**'] },
}
: {
host: '127.0.0.1', port: 5173, strictPort: true,
// 不 watch src-tauri/targetCargo 编译期间写 dll 会触发 EBUSY 崩掉 watcher
watch: { ignored: ['**/src-tauri/target/**'] },
},
// 桌面模式 HMR 由 tauri-cli 管理,无需自动打开浏览器
clearScreen: false,
}))