From 24969d0d3e28d91eba43eeb40282b9033ac32044 Mon Sep 17 00:00:00 2001 From: "Gan, Jimmy" Date: Wed, 8 Apr 2026 00:47:31 +0800 Subject: [PATCH] fix: add compilerOptions to Svelte plugin in vitest config The Svelte plugin was receiving an incomplete config object, causing Object.values() to fail on undefined in the hot-update plugin. Added compilerOptions.dev to provide a complete plugin configuration. --- dashboard/frontend/vitest.config.js | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/dashboard/frontend/vitest.config.js b/dashboard/frontend/vitest.config.js index d1abaaa..6078a54 100644 --- a/dashboard/frontend/vitest.config.js +++ b/dashboard/frontend/vitest.config.js @@ -2,7 +2,14 @@ import { defineConfig } from 'vitest/config'; import { svelte } from '@sveltejs/vite-plugin-svelte'; export default defineConfig({ - plugins: [svelte({ hot: !process.env.VITEST })], + plugins: [ + svelte({ + hot: !process.env.VITEST, + compilerOptions: { + dev: true + } + }) + ], test: { globals: true, environment: 'jsdom',