diff --git a/vite.config.ts b/vite.config.ts index eb74e77..30d1939 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -2,14 +2,16 @@ import { defineConfig } from "vite"; import { svelte } from "@sveltejs/vite-plugin-svelte"; // Tauri loads the dev server from a fixed port and fails if it is taken, and -// rebuilds the Rust side itself, so Vite must not watch src-tauri. +// rebuilds the Rust side itself, so Vite must not watch src-tauri - nor the +// workspace's target/ at the repo root, whose DLLs the build holds locked +// (watching one crashes Vite with EBUSY). export default defineConfig({ plugins: [svelte()], clearScreen: false, server: { port: 1420, strictPort: true, - watch: { ignored: ["**/src-tauri/**"] }, + watch: { ignored: ["**/src-tauri/**", "**/target/**"] }, }, envPrefix: ["VITE_", "TAURI_ENV_"], build: {