1 Star 0 Fork 4

hong/vueAdminPlus

forked from wilkwo/vueAdminPlus 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
vite.config.ts 1.47 KB
一键复制 编辑 原始数据 按行查看 历史
wilkwo 提交于 2024-02-04 21:47 . 更新promote-service地址
import { fileURLToPath, URL } from "node:url";
import { defineConfig } from "vite";
import vue from "@vitejs/plugin-vue";
import vueJsx from "@vitejs/plugin-vue-jsx";
// https://vitejs.dev/config/
export default defineConfig({
plugins: [vue(), vueJsx()],
resolve: {
alias: {
"@": fileURLToPath(new URL("./src", import.meta.url)),
},
},
base: "./", // 当前目录
server: {
host: "127.0.0.1",
port: 7910,
open: true, // 默认打开浏览器
proxy: {
"/manage-service": {
target: "https://admin.dsiab.com",
// target: "http://localhost:8093/",
changeOrigin: true,
// rewrite: (path) => path.replace("manage-service", ""),
},
"/promote-service": {
// target: "https://admin.dsiab.com",
target: 'http://localhost:8095/',
changeOrigin: true,
rewrite: path => path.replace('promote-service', '')
},
},
},
build: {
rollupOptions: {
output: {
manualChunks: {
"vue-router": ["vue-router"],
'vue': ["vue"],
'echarts': ["echarts"],
'wangeditor': ["@wangeditor/editor"],
"@wangeditor-editorforvue": ["@wangeditor/editor-for-vue"],
'axios': ["axios"],
"element-plus": ["element-plus"],
},
entryFileNames: "assets/js/[name]-[hash].js",
chunkFileNames: "assets/js/[name]-[hash].js",
assetFileNames: "assets/[ext]/[name]-[hash].[ext]",
},
},
},
});
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
JavaScript
1
https://gitee.com/githongmayun/vue-admin-plus.git
git@gitee.com:githongmayun/vue-admin-plus.git
githongmayun
vue-admin-plus
vueAdminPlus
master

搜索帮助