template tutoring-admin-dashboard v1
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
import react from '@vitejs/plugin-react';
|
||||
import { defineConfig } from 'vite';
|
||||
|
||||
import { vcBabelLoc } from './vc/inspector';
|
||||
|
||||
// Deploy owns `base` and the /api proxy. Changing them here breaks the deployed
|
||||
// app while dev keeps working — the worst kind of change to make.
|
||||
// `vc/` is DevVibeCoder's Design mode: source-location stamps, dev server only.
|
||||
export default defineConfig(({ command }) => ({
|
||||
plugins: [react(command === 'serve' ? { babel: { plugins: [vcBabelLoc] } } : {})],
|
||||
server: {
|
||||
proxy: {
|
||||
'/api': {
|
||||
target: process.env.VITE_API_URL || 'http://localhost:8000',
|
||||
changeOrigin: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
}));
|
||||
Reference in New Issue
Block a user