| import path from 'path';
|
| import { defineConfig } from 'vite';
|
| import react from '@vitejs/plugin-react-swc';
|
|
|
| import tailwindcss from '@tailwindcss/vite';
|
| import tanstackRouter from '@tanstack/router-plugin/vite';
|
|
|
|
|
| export default defineConfig({
|
| plugins: [
|
| tanstackRouter({
|
| target: 'react',
|
| autoCodeSplitting: true,
|
| }),
|
| react(),
|
|
|
|
|
|
|
|
|
|
|
|
|
| tailwindcss(),
|
| ],
|
| resolve: {
|
| alias: {
|
| '@': path.resolve(__dirname, './src'),
|
|
|
|
|
|
|
| '@tabler/icons-react': '@tabler/icons-react/dist/esm/icons/index.mjs',
|
| },
|
| },
|
| server: {
|
| port: process.env.VITE_PORT ? parseInt(process.env.VITE_PORT) : 5173,
|
| proxy: {
|
| '/admin': {
|
| target: process.env.VITE_API_URL || 'http://localhost:8090',
|
| changeOrigin: true,
|
| },
|
| '/v1': {
|
| target: process.env.VITE_API_URL || 'http://localhost:8090',
|
| changeOrigin: true,
|
| },
|
| },
|
| },
|
| });
|
|
|