diff --git a/package.json b/package.json index 5336f5b..9615f71 100755 --- a/package.json +++ b/package.json @@ -11,7 +11,7 @@ "test": "karma start --single-run", "test_watch": "karma start", "watch": "webpack --progress --watch", - "start": "webpack-dev-server --host 0.0.0.0 --content-base public/ --output-public-path latest/ --hot", + "start": "webpack-dev-server", "build": "webpack", "release": "webpack --progress --optimize-minimize --output-filename clappr-stats.min.js" }, diff --git a/webpack.config.js b/webpack.config.js index f7b7211..cb9e31e 100755 --- a/webpack.config.js +++ b/webpack.config.js @@ -1,3 +1,4 @@ +var webpack = require('webpack'); var path = require('path'); module.exports = { @@ -16,10 +17,21 @@ module.exports = { resolve: { extensions: ['.js'] }, + plugins: [ + new webpack.NamedModulesPlugin(), + new webpack.HotModuleReplacementPlugin() + ], output: { path: path.resolve(__dirname, 'dist'), + publicPath: 'latest/', filename: 'clappr-stats.js', library: 'ClapprStats', libraryTarget: 'umd', }, + devServer: { + contentBase: 'public/', + host: '0.0.0.0', + disableHostCheck: true, + hot: true + } }; \ No newline at end of file