| | |
| | | }, |
| | | proxy: { |
| | | // 跨域配置 |
| | | "/api": { |
| | | target: `http://42.193.1.25:8082`, |
| | | changeOrigin: true, |
| | | pathRewrite: { |
| | | "^/api": '' |
| | | } |
| | | "/sccg": { |
| | | target: `http://42.193.1.25/`, |
| | | // target: `http://127.0.0.1:8082/`, |
| | | changeOrigin: true |
| | | } |
| | | }, |
| | | // disableHostCheck: true |
| | |
| | | config |
| | | .when(process.env.NODE_ENV !== 'development', |
| | | config => { |
| | | // config |
| | | // .plugin('ScriptExtHtmlWebpackPlugin') |
| | | // .after('html') |
| | | // .use('script-ext-html-webpack-plugin', [{ |
| | | // // `runtime` must same as runtimeChunk name. default is `runtime` |
| | | // inline: /runtime\..*\.js$/ |
| | | // }]) |
| | | // .end() |
| | | config |
| | | .optimization.splitChunks({ |
| | | chunks: 'all', |