fix(frontend): add type=module and svelte-preprocess to fix ESM build
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
"name": "hiveops-guide-frontend",
|
||||
"version": "1.0.0",
|
||||
"private": true,
|
||||
"type": "module",
|
||||
"scripts": {
|
||||
"dev": "vite",
|
||||
"build": "vite build",
|
||||
@@ -13,6 +14,7 @@
|
||||
"@tsconfig/svelte": "^5.0.0",
|
||||
"svelte": "^4.0.0",
|
||||
"svelte-check": "^3.0.0",
|
||||
"svelte-preprocess": "^5.0.0",
|
||||
"typescript": "^5.0.0",
|
||||
"vite": "^5.0.0"
|
||||
},
|
||||
|
||||
@@ -1,8 +1,13 @@
|
||||
import { defineConfig } from 'vite';
|
||||
import { svelte } from '@sveltejs/vite-plugin-svelte';
|
||||
import { defineConfig } from 'vite'
|
||||
import { svelte } from '@sveltejs/vite-plugin-svelte'
|
||||
import sveltePreprocess from 'svelte-preprocess'
|
||||
|
||||
export default defineConfig({
|
||||
plugins: [svelte()],
|
||||
plugins: [
|
||||
svelte({
|
||||
preprocess: sveltePreprocess({ typescript: true })
|
||||
})
|
||||
],
|
||||
server: { port: 5188 },
|
||||
preview: { port: 5188 },
|
||||
});
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user