From 3063d9c86511a5b91ad0d27e40c41d06f88939b4 Mon Sep 17 00:00:00 2001 From: Pan Date: Sat, 29 Apr 2017 16:36:14 +0800 Subject: [PATCH] replace NoErrorsPlugin && add dev eslint check --- build/webpack.base.conf.js | 18 +++++++++--------- build/webpack.dev.conf.js | 2 +- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/build/webpack.base.conf.js b/build/webpack.base.conf.js index 64fe3303..820cc528 100644 --- a/build/webpack.base.conf.js +++ b/build/webpack.base.conf.js @@ -41,15 +41,15 @@ module.exports = { }, module: { rules: [ - // { - // test: /\.(js|vue)$/, - // loader: 'eslint-loader', - // enforce: "pre", - // include: [resolve('src'), resolve('test')], - // options: { - // formatter: require('eslint-friendly-formatter') - // } - // }, + { + test: /\.(js|vue)$/, + loader: 'eslint-loader', + enforce: "pre", + include: [resolve('src'), resolve('test')], + options: { + formatter: require('eslint-friendly-formatter') + } + }, { test: /\.vue$/, loader: 'vue-loader', options: vueLoaderConfig diff --git a/build/webpack.dev.conf.js b/build/webpack.dev.conf.js index 109a7970..1cc0a90b 100644 --- a/build/webpack.dev.conf.js +++ b/build/webpack.dev.conf.js @@ -33,7 +33,7 @@ module.exports = merge(baseWebpackConfig, { }), // https://github.com/glenjamin/webpack-hot-middleware#installation--usage new webpack.HotModuleReplacementPlugin(), - new webpack.NoErrorsPlugin(), + new webpack.NoEmitOnErrorsPlugin(), // https://github.com/ampedandwired/html-webpack-plugin new HtmlWebpackPlugin({ filename: 'index.html',