var path = require('path');
var webpack = require('webpack');

module.exports = {
  devtool: 'eval',
  entry: [
    'webpack-dev-server/client?http://localhost:3000',
    'webpack/hot/only-dev-server',
    './src/index'
  ],
  output: {
    path: path.join(__dirname, 'dist'),
    filename: 'bundle.js',
    publicPath: '/dist/'
  },
  plugins: [
    new webpack.HotModuleReplacementPlugin()
  ],
  module: {
    loaders: [{
      test: /\.js$/,
      loaders: ['react-hot', 'babel'],
      include: path.join(__dirname, 'src')
    }, {
      test: /\.css$/,
      loader: 'style!css?modules',
      include: /flexboxgrid/,
    }]
  }
};

@@ -59,147 +59,69 @@
 ');%0A
-%0Amodule.exports = %7B%0A  devtool: 'eval',%0A  entry: %5B%0A    'webpack-dev-server/client?http://localhost:3000',%0A    'webpack/hot/only-dev-server',
+var env = process.env.NODE_ENV%0A%0Avar baseConfig = %7B%0A  entry: %5B
 %0A   
@@ -258,24 +258,473 @@
  plugins: %5B%0A
+    new webpack.DefinePlugin(%7B%0A      __DEV__: env !== 'production',%0A      NODE_ENV: JSON.stringify(env)%0A    %7D)%0A  %5D,%0A  module: %7B%0A    loaders: %5B%7B%0A      test: /%5C.css$/,%0A      loader: 'style!css?modules',%0A      include: /flexboxgrid/,%0A    %7D%5D%0A  %7D%0A%7D;%0A%0Aif (env !== 'production') %7B%0A  baseConfig.devtool = 'eval'%0A  baseConfig.entry.push(%0A    'webpack-dev-server/client?http://localhost:3000',%0A    'webpack/hot/only-dev-server'%0A  )%0A  baseConfig.plugins.push(%0A
     new webp
@@ -762,41 +762,45 @@
 )%0A  
-%5D,%0A  module: %7B%0A    loaders: %5B%7B%0A  
+)%0A  baseConfig.module.loaders.push(%7B%0A
     
@@ -814,26 +814,24 @@
 %5C.js$/,%0A    
-  
 loaders: %5B'r
@@ -851,18 +851,16 @@
 abel'%5D,%0A
-  
     incl
@@ -898,17 +898,157 @@
 )%0A  
-  %7D, %7B%0A  
+%7D)%0A%7D else %7B%0A  baseConfig.plugins.push(%0A    new webpack.optimize.UglifyJsPlugin(%7B%0A      warning: false%0A    %7D)%0A  )%0A%0A  baseConfig.module.loaders.push(%7B%0A
     
@@ -1052,33 +1052,30 @@
    test: /%5C.
-cs
+j
 s$/,%0A
-  
     loader: 
@@ -1076,71 +1076,95 @@
 ader
+s
 : 
-'style!css?modules',%0A      include: /flexboxgrid/,%0A    %7D%5D%0A  %7D%0A%7D;
+%5B'babel'%5D,%0A    include: path.join(__dirname, 'src')%0A  %7D)%0A%7D%0A%0Amodule.exports = baseConfig
 %0A

Update config