Files
vod-system/frontend/vite.config.ts
Dylan De Faoite 761f93e2a7
All checks were successful
CI / Maven unit tests (push) Successful in 17s
CI / Build and push images (push) Has been skipped
CI / Deploy to server (push) Has been skipped
feat: overhaul frontend styling
2026-07-29 10:16:09 +01:00

30 lines
730 B
TypeScript

import { defineConfig, loadEnv } from 'vite'
import react from '@vitejs/plugin-react'
import tailwindcss from '@tailwindcss/vite'
export default defineConfig(({ mode }) => { // change to function form
const env = loadEnv(mode, process.cwd(), '') // load all env vars
return {
plugins: [react(), tailwindcss()],
preview: {
port: 5173,
strictPort: true,
},
server: {
port: 5173,
strictPort: true,
host: true,
origin: env.VITE_FRONTEND_URL || "http://0.0.0.0:5173", // use it here
allowedHosts: true,
proxy: {
'/api/v1': {
target: 'http://localhost:8080',
changeOrigin: true,
secure: false,
}
}
}
}
})