23 lines
472 B
JavaScript
23 lines
472 B
JavaScript
import { defineConfig } from 'vite';
|
|
import react from '@vitejs/plugin-react';
|
|
|
|
export default defineConfig({
|
|
plugins: [react()],
|
|
server: {
|
|
host: true,
|
|
port: 5173,
|
|
proxy: {
|
|
'/api': {
|
|
target: process.env.VITE_API_URL || 'http://localhost:3000',
|
|
changeOrigin: true,
|
|
rewrite: (path) => path.replace(/^\/api/, '/api')
|
|
}
|
|
}
|
|
},
|
|
build: {
|
|
outDir: 'dist',
|
|
sourcemap: false,
|
|
chunkSizeWarningLimit: 1000
|
|
}
|
|
});
|