import { defineConfig } from 'vite' import vue from '@vitejs/plugin-vue' export default defineConfig({ plugins: [vue()], server: { port: 5173, // Preserve the browser-facing Host so the API's same-origin guard can // compare it with Origin. Vite's string shorthand enables changeOrigin. proxy: { '/api': { target: 'http://127.0.0.1:18081', changeOrigin: false, }, } }, test: { environment: 'jsdom', globals: true, }, })