56 lines
976 B
JavaScript
56 lines
976 B
JavaScript
/*
|
||
* @Descripttion:
|
||
* @version:
|
||
* @Author: kBank
|
||
* @Date: 2022-09-29 10:04:55
|
||
*/
|
||
// 引入等比适配插件
|
||
const px2rem = require("postcss-px2rem");
|
||
|
||
// 配置基本大小
|
||
const postcss = px2rem({
|
||
// 基准大小 baseSize,需要和rem.js中相同
|
||
remUnit: 16,
|
||
});
|
||
|
||
// 使用等比适配插件
|
||
module.exports = {
|
||
lintOnSave: false,
|
||
devServer: {
|
||
port: 8866,
|
||
proxy: {
|
||
"/prod-api": {
|
||
target: "http://localhost:8080",
|
||
changeOrigin: true,
|
||
pathRewrite: {
|
||
"^/prod-api": "",
|
||
},
|
||
},
|
||
},
|
||
},
|
||
|
||
css: {
|
||
loaderOptions: {
|
||
postcss: {
|
||
plugins: [postcss],
|
||
},
|
||
},
|
||
},
|
||
configureWebpack: {
|
||
externals: {
|
||
enUS: "enUS",
|
||
zhCN: "zhCN",
|
||
zhTC: "zhTC",
|
||
ruRU: "ruRU",
|
||
frFR: "frFR",
|
||
ptPT: "ptPT",
|
||
},
|
||
},
|
||
chainWebpack: (config) => {
|
||
config.plugin("html").tap((args) => {
|
||
args[0].title = "会员系统";
|
||
return args;
|
||
});
|
||
},
|
||
};
|