| | |
| | | return path.join(__dirname, dir) |
| | | } |
| | | |
| | | const name = process.env.VUE_APP_TITLE || '若依管理系统' // 网页标题 |
| | | const name = process.env.VUE_APP_TITLE || '浙江省OPO数字化管理系统' // 网页标题 |
| | | |
| | | const port = process.env.port || process.env.npm_config_port || 80 // 端口 |
| | | |
| | |
| | | proxy: { |
| | | // detail: https://cli.vuejs.org/config/#devserver-proxy |
| | | [process.env.VUE_APP_BASE_API]: { |
| | | target: `http://localhost:8080`, |
| | | // target:`http://slb.hospitalstar.com:9091`, |
| | | // target1:`http://192.168.2.3:8080`, |
| | | target:`http://localhost:8080`, |
| | | // target:`http://192.168.1.10:8080`, |
| | | // target:`http://116.62.18.175:8080`, |
| | | // target:`https://slb.hospitalstar.com:9093`, |
| | | changeOrigin: true, |
| | | pathRewrite: (path) => path.replace(/^\/dev-api/, '') |
| | | pathRewrite: { |
| | | ['^' + process.env.VUE_APP_BASE_API]: '' |
| | | } |
| | | } |
| | | }, |
| | | disableHostCheck: true |
| | |
| | | resolve: { |
| | | alias: { |
| | | '@': resolve('src') |
| | | |
| | | } |
| | | } |
| | | }, |
| | |
| | | .plugin('ScriptExtHtmlWebpackPlugin') |
| | | .after('html') |
| | | .use('script-ext-html-webpack-plugin', [{ |
| | | // `runtime` must same as runtimeChunk name. default is `runtime` |
| | | // `runtime` must same as runtimeChunk name. default is `runtime` |
| | | inline: /runtime\..*\.js$/ |
| | | }]) |
| | | .end() |
| | |
| | | }) |
| | | config.optimization.runtimeChunk('single'), |
| | | { |
| | | from: path.resolve(__dirname, './public/robots.txt'), //防爬虫文件 |
| | | to: './' //到根目录下 |
| | | from: path.resolve(__dirname, './public/robots.txt'), //防爬虫文件 |
| | | to: './' //到根目录下 |
| | | } |
| | | } |
| | | ) |