diff --git a/build/webpack.base.conf.js b/build/webpack.base.conf.js index 3b946b4b..2d8ec5b8 100644 --- a/build/webpack.base.conf.js +++ b/build/webpack.base.conf.js @@ -23,7 +23,7 @@ const createLintingRule = () => ({ module.exports = { context: path.resolve(__dirname, '../'), entry: { - app: './src/main.js' + app: ['babel-polyfill', './src/main.js'] }, output: { path: config.build.assetsRoot, diff --git a/build/webpack.dev.conf.js b/build/webpack.dev.conf.js index 26a5584a..b3b95bee 100644 --- a/build/webpack.dev.conf.js +++ b/build/webpack.dev.conf.js @@ -59,9 +59,9 @@ const devWebpackConfig = merge(baseWebpackConfig, { favicon: resolve('favicon.ico'), title: 'vue-element-admin', templateParameters: { - BASE_URL: config.dev.assetsPublicPath + config.dev.assetsSubDirectory, - }, - }), + BASE_URL: config.dev.assetsPublicPath + config.dev.assetsSubDirectory + } + }) ] }) diff --git a/build/webpack.prod.conf.js b/build/webpack.prod.conf.js index 4f84e0c6..5fa029a0 100644 --- a/build/webpack.prod.conf.js +++ b/build/webpack.prod.conf.js @@ -57,7 +57,7 @@ const webpackConfig = merge(baseWebpackConfig, { favicon: resolve('favicon.ico'), title: 'vue-element-admin', templateParameters: { - BASE_URL: config.build.assetsPublicPath + config.build.assetsSubDirectory, + BASE_URL: config.build.assetsPublicPath + config.build.assetsSubDirectory }, minify: { removeComments: true, @@ -71,7 +71,7 @@ const webpackConfig = merge(baseWebpackConfig, { // matter anyway }), new ScriptExtHtmlWebpackPlugin({ - //`runtime` must same as runtimeChunk name. default is `runtime` + // `runtime` must same as runtimeChunk name. default is `runtime` inline: /runtime\..*\.js$/ }), // keep chunk.id stable when chunk has no name diff --git a/package.json b/package.json index e5b0b9ec..d3cb8427 100644 --- a/package.json +++ b/package.json @@ -72,6 +72,7 @@ "babel-plugin-syntax-jsx": "6.18.0", "babel-plugin-transform-runtime": "6.23.0", "babel-plugin-transform-vue-jsx": "3.7.0", + "babel-polyfill": "^6.26.0", "babel-preset-env": "1.7.0", "babel-preset-stage-2": "6.24.1", "chalk": "2.4.1", @@ -89,9 +90,9 @@ "html-webpack-plugin": "4.0.0-alpha", "husky": "0.14.3", "lint-staged": "7.2.2", - "mini-css-extract-plugin": "0.4.1", + "mini-css-extract-plugin": "^0.4.1", "node-notifier": "5.2.1", - "node-sass": "^4.7.2", + "node-sass": "^4.11.0", "optimize-css-assets-webpack-plugin": "5.0.0", "ora": "3.0.0", "path-to-regexp": "2.4.0", @@ -100,7 +101,7 @@ "postcss-loader": "2.1.6", "postcss-url": "7.3.2", "rimraf": "2.6.2", - "sass-loader": "7.0.3", + "sass-loader": "^7.0.3", "script-ext-html-webpack-plugin": "2.0.1", "script-loader": "0.7.2", "semver": "5.5.0",