From 9b608b89b16953c8d717ed8fde02ae396eea6094 Mon Sep 17 00:00:00 2001 From: Indrajith K L Date: Tue, 19 Dec 2017 19:10:01 +0530 Subject: * Webpack config changes * Updated documentation with example * removed unwanted dependencies from starter pack --- webpack.config.js | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'webpack.config.js') diff --git a/webpack.config.js b/webpack.config.js index e88631d..33c1e5f 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -1,10 +1,12 @@ const webpack = require("webpack"); const path = require("path"); -const HtmlWebpackPlugin = require("html-webpack-plugin"); const DashboardPlugin = require("webpack-dashboard/plugin"); +const WebpackShellPlugin = require('webpack-shell-plugin'); + + const nodeEnv = process.env.NODE_ENV || "development"; const isProd = nodeEnv === "production"; - +console.log(webpack.plugins); var config = { devtool: isProd ? "hidden-source-map" : "source-map", context: path.resolve("./src"), @@ -45,7 +47,6 @@ var config = { output: { comments: false }, sourceMap: true }), - new DashboardPlugin(), new webpack.LoaderOptionsPlugin({ options: { tslint: { @@ -53,6 +54,9 @@ var config = { failOnHint: true } } + }), + new WebpackShellPlugin({ + onBuildEnd: 'cp -r dist/* docs/example/' }) ], devServer: { -- cgit v1.2.3