|
@@ -6,7 +6,6 @@ const defaultSettings = require('./src/settings.js')
|
|
function resolve(dir) {
|
|
function resolve(dir) {
|
|
return path.join(__dirname, dir)
|
|
return path.join(__dirname, dir)
|
|
}
|
|
}
|
|
-
|
|
|
|
const name = defaultSettings.title || 'go-dmin' // page title
|
|
const name = defaultSettings.title || 'go-dmin' // page title
|
|
|
|
|
|
// If your port is set to 80,
|
|
// If your port is set to 80,
|
|
@@ -15,7 +14,6 @@ const name = defaultSettings.title || 'go-dmin' // page title
|
|
// You can change the port by the following method:
|
|
// You can change the port by the following method:
|
|
// port = 9527 npm run dev OR npm run dev --port = 9527
|
|
// port = 9527 npm run dev OR npm run dev --port = 9527
|
|
const port = process.env.port || process.env.npm_config_port || 9527 // dev port
|
|
const port = process.env.port || process.env.npm_config_port || 9527 // dev port
|
|
-
|
|
|
|
// const MonacoWebpackPlugin = require('monaco-editor-webpack-plugin')
|
|
// const MonacoWebpackPlugin = require('monaco-editor-webpack-plugin')
|
|
|
|
|
|
// All configuration item explanations can be find in https://cli.vuejs.org/config/
|
|
// All configuration item explanations can be find in https://cli.vuejs.org/config/
|
|
@@ -60,7 +58,7 @@ module.exports = {
|
|
configureWebpack: {
|
|
configureWebpack: {
|
|
plugins: [
|
|
plugins: [
|
|
new CompressionPlugin({
|
|
new CompressionPlugin({
|
|
- cache:false,
|
|
|
|
|
|
+ cache: false,
|
|
algorithm: 'gzip',
|
|
algorithm: 'gzip',
|
|
test: /\.js$|\.html$|\.css/, // 匹配文件名
|
|
test: /\.js$|\.html$|\.css/, // 匹配文件名
|
|
threshold: 10240, // 对超过10kb的数据进行压缩
|
|
threshold: 10240, // 对超过10kb的数据进行压缩
|