diff --git a/electron.vite.config.ts b/electron.vite.config.ts index 3cbd8227..62cd48a9 100644 --- a/electron.vite.config.ts +++ b/electron.vite.config.ts @@ -29,6 +29,9 @@ export default defineConfig({ }, }, preload: { + // zod is bundled into preload because preload runs as sandboxed CJS + // and cannot resolve externalized ESM deps at runtime. Inlining keeps + // IPC Zod validation working inside the preload layer. plugins: [externalizeDepsPlugin({ exclude: ["zod"] })], resolve: { alias: {