Files
maps-saas/apps/dashboard/vite.config.ts
T
2026-04-15 01:05:15 +03:00

26 lines
551 B
TypeScript

import { defineConfig } from 'vite'
import react from '@vitejs/plugin-react'
export default defineConfig({
plugins: [react()],
server: {
allowedHosts: true,
proxy: {
'/api': {
target: process.env.VITE_API_URL || 'http://api:3200',
changeOrigin: true,
// No rewrite needed since NestJS has a global prefix 'api'
}
}
},
preview: {
allowedHosts: true,
proxy: {
'/api': {
target: process.env.VITE_API_URL || 'http://api:3200',
changeOrigin: true,
}
}
}
})