diff --git a/vite.config.ts b/vite.config.ts
index fac2a627424882618a3ef737a143b705d9753a91..4d2b8fa7cd924f406bd6496375d55958ce65d2df 100644
--- a/vite.config.ts
+++ b/vite.config.ts
@@ -1,11 +1,11 @@
 import { sveltekit } from "@sveltejs/kit/vite"
 import yaml from "js-yaml"
-import type { UserConfig } from "vite"
+import { defineConfig } from "vite"
 
 // import yamlPlugin from "@rollup/plugin-yaml"
 import yamlPlugin from "./plugin-yaml-patched"
 
-const config: UserConfig = {
+export default defineConfig({
   build: {
     // Increase size of chunks to 5 MB, to be able to import
     // JSON files extracted from OpenFisca country package.
@@ -25,6 +25,4 @@ const config: UserConfig = {
   ssr: {
     noExternal: ["d3-scale"],
   },
-}
-
-export default config
+})