update from RIFT as of 696b75d2fe9fb046261b08c616f1bcf6c0b54a9b third try
[osm/UI.git] / skyquake / plugins / helloworld / webpack.production.config.js
index 7db6acc..82ac524 100644 (file)
@@ -26,6 +26,7 @@ var HtmlWebpackPlugin = require('html-webpack-plugin');
 var CompressionPlugin = require("compression-webpack-plugin");
 // Added to overcome node-sass bug https://github.com/iam4x/isomorphic-flux-boilerplate/issues/62
 process.env.UV_THREADPOOL_SIZE=64;
+var htmlFilename = (process.argv.indexOf('--production-debug') !== -1) ? 'debug.html' : 'index.html';
 var config = {
     devtool: 'source-map',
     entry: mainPath,
@@ -65,7 +66,7 @@ var config = {
     },
     plugins: [
         new HtmlWebpackPlugin({
-            filename: '../index.html'
+            filename: '../' + htmlFilename
             templateContent: '<div id="content"></div>'
         })
     ]