Adaption of dashboard to Vite and React

This commit is contained in:
2025-09-13 10:03:50 +00:00
parent 1d23b7591d
commit c5a8571e97
6 changed files with 87 additions and 114 deletions

View File

@@ -1,16 +1,20 @@
import { defineConfig } from 'vite';
import react from '@vitejs/plugin-react';
// import path from 'path';
// https://vite.dev/config/
export default defineConfig({
plugins: [react()],
resolve: {
alias: {
'@syncfusion/ej2-react-navigations': '@syncfusion/ej2-react-navigations/index.js',
'@syncfusion/ej2-react-buttons': '@syncfusion/ej2-react-buttons/index.js',
},
// 🔧 KORRIGIERT: Entferne die problematischen Aliases komplett
// Diese verursachen das "not an absolute path" Problem
// alias: {
// '@syncfusion/ej2-react-navigations': '@syncfusion/ej2-react-navigations/index.js',
// '@syncfusion/ej2-react-buttons': '@syncfusion/ej2-react-buttons/index.js',
// },
},
optimizeDeps: {
// 🔧 NEU: Force pre-bundling der Syncfusion Module
include: [
'@syncfusion/ej2-react-navigations',
'@syncfusion/ej2-react-buttons',
@@ -19,6 +23,7 @@ export default defineConfig({
'@syncfusion/ej2-buttons',
'@syncfusion/ej2-react-base',
],
// 🔧 NEU: Force dependency re-optimization
force: true,
esbuildOptions: {
target: 'es2020',
@@ -33,6 +38,7 @@ export default defineConfig({
},
server: {
host: '0.0.0.0',
port: 5173,
watch: {
usePolling: true,
},