|
|
@ -5,7 +5,7 @@ const GitRevision = new GitRevisionPlugin() |
|
|
|
const buildDate = JSON.stringify(new Date().toLocaleString()) |
|
|
|
const buildDate = JSON.stringify(new Date().toLocaleString()) |
|
|
|
const createThemeColorReplacerPlugin = require('./config/plugin.config') |
|
|
|
const createThemeColorReplacerPlugin = require('./config/plugin.config') |
|
|
|
|
|
|
|
|
|
|
|
function resolve (dir) { |
|
|
|
function resolve(dir) { |
|
|
|
return path.join(__dirname, dir) |
|
|
|
return path.join(__dirname, dir) |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
@ -35,6 +35,9 @@ const vueConfig = { |
|
|
|
publicPath: process.env.NODE_ENV === 'production' ? './' : '/', |
|
|
|
publicPath: process.env.NODE_ENV === 'production' ? './' : '/', |
|
|
|
|
|
|
|
|
|
|
|
configureWebpack: { |
|
|
|
configureWebpack: { |
|
|
|
|
|
|
|
performance: { |
|
|
|
|
|
|
|
hints: false, |
|
|
|
|
|
|
|
}, |
|
|
|
// webpack plugins
|
|
|
|
// webpack plugins
|
|
|
|
plugins: [ |
|
|
|
plugins: [ |
|
|
|
// Ignore all locale files of moment.js
|
|
|
|
// Ignore all locale files of moment.js
|
|
|
@ -50,8 +53,7 @@ const vueConfig = { |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
chainWebpack: (config) => { |
|
|
|
chainWebpack: (config) => { |
|
|
|
config.resolve.alias |
|
|
|
config.resolve.alias.set('@$', resolve('src')) |
|
|
|
.set('@$', resolve('src')) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
const svgRule = config.module.rule('svg') |
|
|
|
const svgRule = config.module.rule('svg') |
|
|
|
svgRule.uses.clear() |
|
|
|
svgRule.uses.clear() |
|
|
@ -66,7 +68,7 @@ const vueConfig = { |
|
|
|
.use('file-loader') |
|
|
|
.use('file-loader') |
|
|
|
.loader('file-loader') |
|
|
|
.loader('file-loader') |
|
|
|
.options({ |
|
|
|
.options({ |
|
|
|
name: 'assets/[name].[hash:8].[ext]' |
|
|
|
name: 'assets/[name].[hash:8].[ext]', |
|
|
|
}) |
|
|
|
}) |
|
|
|
|
|
|
|
|
|
|
|
// if prod is on
|
|
|
|
// if prod is on
|
|
|
@ -96,17 +98,17 @@ const vueConfig = { |
|
|
|
// 'link-color': '#1890ff',
|
|
|
|
// 'link-color': '#1890ff',
|
|
|
|
|
|
|
|
|
|
|
|
'font-size-base': '13px', |
|
|
|
'font-size-base': '13px', |
|
|
|
'border-radius-base': '2px' |
|
|
|
'border-radius-base': '2px', |
|
|
|
}, |
|
|
|
}, |
|
|
|
// DO NOT REMOVE THIS LINE
|
|
|
|
// DO NOT REMOVE THIS LINE
|
|
|
|
javascriptEnabled: true |
|
|
|
javascriptEnabled: true, |
|
|
|
} |
|
|
|
}, |
|
|
|
} |
|
|
|
}, |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
devServer: { |
|
|
|
devServer: { |
|
|
|
// development server port 8000
|
|
|
|
// development server port 8000
|
|
|
|
port: 8220 |
|
|
|
port: 8220, |
|
|
|
// If you want to turn on the proxy, please remove the mockjs /src/main.jsL11
|
|
|
|
// If you want to turn on the proxy, please remove the mockjs /src/main.jsL11
|
|
|
|
// proxy: {
|
|
|
|
// proxy: {
|
|
|
|
// '/api': {
|
|
|
|
// '/api': {
|
|
|
@ -124,7 +126,7 @@ const vueConfig = { |
|
|
|
productionSourceMap: false, |
|
|
|
productionSourceMap: false, |
|
|
|
lintOnSave: false, |
|
|
|
lintOnSave: false, |
|
|
|
// babel-loader no-ignore node_modules/*
|
|
|
|
// babel-loader no-ignore node_modules/*
|
|
|
|
transpileDependencies: [] |
|
|
|
transpileDependencies: [], |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
// preview.pro.loacg.com only do not use in your production;
|
|
|
|
// preview.pro.loacg.com only do not use in your production;
|
|
|
|