Files
botgroup.chat/vite.config.ts
2025-02-12 17:18:18 +08:00

32 lines
631 B
TypeScript

import { defineConfig } from 'vite'
import react from '@vitejs/plugin-react'
import path from 'path'
export default defineConfig({
plugins: [react()],
base: '/',
server: {
port: 3000,
open: true,
host: true,
// 如果有跨域需求,可以添加代理配置
// proxy: {
// '/api': {
// target: 'your-api-url',
// changeOrigin: true,
// rewrite: (path) => path.replace(/^\/api/, '')
// }
// }
},
resolve: {
alias: {
"@": path.resolve(__dirname, "./src"),
},
},
build: {
target: 'esnext',
minify: 'esbuild',
outDir: 'dist'
}
})