Replace the health-check stub UI with a left menu and content panel so section navigation and frontend/backend versions are visible in the shell.
26 lines
607 B
TypeScript
26 lines
607 B
TypeScript
import { readFileSync } from 'node:fs'
|
|
import { defineConfig } from 'vitest/config'
|
|
import react from '@vitejs/plugin-react'
|
|
|
|
const packageJson = JSON.parse(
|
|
readFileSync(new URL('./package.json', import.meta.url), 'utf-8'),
|
|
) as { version: string }
|
|
|
|
export default defineConfig({
|
|
plugins: [react()],
|
|
define: {
|
|
__FRONTEND_VERSION__: JSON.stringify(packageJson.version),
|
|
},
|
|
server: {
|
|
proxy: {
|
|
'/health': 'http://localhost:8080',
|
|
'/api': 'http://localhost:8080',
|
|
},
|
|
},
|
|
test: {
|
|
environment: 'jsdom',
|
|
setupFiles: ['./src/test/setup.ts'],
|
|
globals: true,
|
|
},
|
|
})
|