2024-02-02 15:04:47 +08:00
|
|
|
module.exports = {
|
|
|
|
|
//路径前缀
|
2024-02-04 13:38:23 +08:00
|
|
|
publicPath: "/manage/",
|
2024-03-15 10:24:46 +08:00
|
|
|
outputDir: "manage",
|
2024-02-02 15:04:47 +08:00
|
|
|
lintOnSave: true,
|
|
|
|
|
productionSourceMap: false,
|
2024-02-04 13:38:23 +08:00
|
|
|
chainWebpack: config => {
|
2024-02-02 15:04:47 +08:00
|
|
|
//忽略的打包文件
|
|
|
|
|
config.externals({
|
2024-02-04 13:38:23 +08:00
|
|
|
vue: "Vue",
|
|
|
|
|
"vue-router": "VueRouter",
|
|
|
|
|
vuex: "Vuex",
|
|
|
|
|
axios: "axios",
|
|
|
|
|
"element-ui": "ELEMENT"
|
2024-02-02 15:04:47 +08:00
|
|
|
});
|
2024-02-04 13:38:23 +08:00
|
|
|
const entry = config.entry("app");
|
|
|
|
|
entry.add("babel-polyfill").end();
|
|
|
|
|
entry.add("classlist-polyfill").end();
|
|
|
|
|
entry.add("@/mock").end();
|
2024-02-02 15:04:47 +08:00
|
|
|
},
|
|
|
|
|
devServer: {
|
2024-02-04 13:38:23 +08:00
|
|
|
host: "0.0.0.0",
|
2024-02-02 15:04:47 +08:00
|
|
|
port: 1888,
|
|
|
|
|
proxy: {
|
2024-02-04 13:38:23 +08:00
|
|
|
"/api": {
|
2024-03-20 22:15:08 +08:00
|
|
|
// target: 'http://10.165.0.173:8000',
|
2024-03-22 09:47:13 +08:00
|
|
|
// target: "http://39.98.184.58:8000", // 阿里云后台地址
|
2024-03-14 10:09:11 +08:00
|
|
|
// target: "http://192.168.3.104:8000", // 本地
|
2024-03-20 12:08:54 +08:00
|
|
|
// target: 'http://192.168.1.106:8000',
|
2024-03-19 17:23:29 +08:00
|
|
|
// target: 'http://192.168.3.173:8000',
|
2024-03-22 09:47:13 +08:00
|
|
|
target: 'http://10.165.0.173:8000',
|
2024-03-20 22:15:08 +08:00
|
|
|
// target: 'http://198.168.3.120:8000',
|
2024-02-02 15:04:47 +08:00
|
|
|
ws: true,
|
2024-02-04 13:38:23 +08:00
|
|
|
changeOrigin: true,
|
2024-02-02 15:04:47 +08:00
|
|
|
pathRewrite: {
|
2024-02-04 13:38:23 +08:00
|
|
|
"^/api": "/"
|
2024-02-02 15:04:47 +08:00
|
|
|
}
|
|
|
|
|
},
|
2024-02-04 22:34:37 +08:00
|
|
|
"/qq/map": {
|
2024-02-02 15:04:47 +08:00
|
|
|
//本地服务接口地址
|
2024-02-04 22:34:37 +08:00
|
|
|
target: "https://apis.map.qq.com",
|
2024-02-02 15:04:47 +08:00
|
|
|
ws: true,
|
|
|
|
|
pathRewrite: {
|
2024-02-04 22:34:37 +08:00
|
|
|
"^/qq/map": "/"
|
2024-02-02 15:04:47 +08:00
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
};
|