2026-07-18 20:09:26 +08:00
|
|
|
import { defineConfig } from 'vite'
|
|
|
|
|
import vue from '@vitejs/plugin-vue'
|
2026-07-18 23:17:53 +08:00
|
|
|
import ElementPlus from 'unplugin-element-plus/vite'
|
2026-07-18 20:09:26 +08:00
|
|
|
|
|
|
|
|
export default defineConfig({
|
2026-07-18 23:17:53 +08:00
|
|
|
plugins: [vue(), ElementPlus()],
|
2026-07-18 20:09:26 +08:00
|
|
|
server: {
|
|
|
|
|
port: 5173,
|
|
|
|
|
proxy: {
|
|
|
|
|
'/api': {
|
|
|
|
|
target: 'http://localhost:8000',
|
|
|
|
|
changeOrigin: true,
|
|
|
|
|
},
|
|
|
|
|
'/admin/api': {
|
|
|
|
|
target: 'http://localhost:8000',
|
|
|
|
|
changeOrigin: true,
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
build: {
|
|
|
|
|
outDir: 'dist',
|
|
|
|
|
emptyOutDir: true,
|
|
|
|
|
},
|
|
|
|
|
})
|