22 lines
438 B
TypeScript
22 lines
438 B
TypeScript
|
import { defineConfig } from 'vite'
|
||
|
import vue from '@vitejs/plugin-vue'
|
||
|
|
||
|
export default defineConfig({
|
||
|
plugins: [vue()],
|
||
|
resolve: {
|
||
|
alias: {
|
||
|
'@': '/src',
|
||
|
},
|
||
|
},
|
||
|
server: {
|
||
|
host: true,
|
||
|
port: 5173,
|
||
|
proxy: {
|
||
|
'/api/crawl': {
|
||
|
target: process.env.VITE_CRAWL_API_URL || 'http://127.0.0.1:5000',
|
||
|
changeOrigin: true,
|
||
|
rewrite: (path) => path.replace(/^\/api/, '')
|
||
|
}
|
||
|
}
|
||
|
},
|
||
|
})
|