1234567891011121314151617181920212223242526272829303132333435363738 |
- module.exports = {
- parallel: false,
- productionSourceMap: false,
- outputDir: './dist',
- publicPath: process.env.VUE_APP_BASE_PUBLIC,
- lintOnSave: true,
- devServer: {
- port: '8080',
- disableHostCheck: true,
- proxy: {
- '^/api-docs': {
- target: 'http://xxx.com/api-docs',
- changeOrigin: true,
- pathRewrite: {
- '^/api-docs': ''
- }
- }
- }
- },
- css: {
- loaderOptions: {
- sass: {
- prependData: '@import "@/assets/style/_mixin.scss";@import "@/assets/style/_variables.scss";'
- }
- }
- },
- chainWebpack: config => {
- if (!process.env.VUE_APP_ALONE) {
- config.devServer.set('inline', false)
- config.devServer.set('hot', true)
- if (process.env.NODE_ENV !== 'production') {
- config.output.filename('js/[name].js')
- }
- config.externals(['vue', 'vue-router'])
- }
- },
- filenameHashing: false
- }
|