From cbd48f85991f9a9f18dac6355b355360e8730528 Mon Sep 17 00:00:00 2001 From: dolymood Date: Tue, 25 Oct 2016 20:55:54 +0800 Subject: [PATCH] add webpack-dev-server and webpack-dashboard --- webpack.config.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/webpack.config.js b/webpack.config.js index d27dbd7..e4be4ea 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -2,6 +2,7 @@ var path = require('path') var webpack = require('webpack') var HtmlWebpackPlugin = require('html-webpack-plugin') var ExtractTextPlugin = require('extract-text-webpack-plugin') +var DashboardPlugin = require('webpack-dashboard/plugin') var pkg = require('./package.json') module.exports = { @@ -35,6 +36,7 @@ module.exports = { formatter: require('eslint-friendly-formatter') }, plugins: [ + new DashboardPlugin(), new webpack.optimize.OccurenceOrderPlugin(), new HtmlWebpackPlugin({ filename: 'example.html', @@ -43,5 +45,8 @@ module.exports = { }), new ExtractTextPlugin(pkg.name + '.min.css') ], - devtool: false + devServer: { + contentBase: 'dev' + }, + devtool: 'source-map' }