This commit is contained in:
2024-09-05 13:10:38 +08:00
commit 663b2c3721
39 changed files with 8523 additions and 0 deletions

35
vite.config.ts Normal file
View File

@@ -0,0 +1,35 @@
import {fileURLToPath, URL} from 'node:url'
import {defineConfig} from 'vite'
import vue from '@vitejs/plugin-vue'
import vueJsx from '@vitejs/plugin-vue-jsx'
//
// const {createProxyMiddleware} = require('http-proxy-middleware');
// app.use('/api', createProxyMiddleware({
// target: '/https:/v3pz.itndedu.com/v3pz/',
// changeOrigin: true,
// pathRewrite: {'^/api': ''}
// }));
//
// // https://vitejs.dev/config/
export default defineConfig({
plugins: [
vue(),
vueJsx(),
],
resolve: {
alias: {
'@': fileURLToPath(new URL('./src', import.meta.url))
}
},
server: {
proxy: {
'/api': {
target: 'https://v3pz.itndedu.com/v3pz/',
changeOrigin: true,
rewrite: (path): any => path.replace("/api", ''),
},
},
},
})