
module.exports = {
  entry: './index.js',

  output: {
    path: 'public',
    filename: 'bundle.js',
    publicPath: '/'
  },
  module: {
    loaders: [
      { test: /\.js$/, exclude: /node_modules/, loader: 'babel-loader?presets[]=es2015&presets[]=react&presets[]=stage-0' }
    ]
  }
}

@@ -1,8 +1,43 @@
+const webpack = require('webpack')%0A
 %0Amodule.
@@ -156,16 +156,160 @@
 /'%0A  %7D,%0A
+  plugins: %5B%0A    new webpack.DefinePlugin(%7B%0A      'process.env': %7B%0A        'NODE_ENV': JSON.stringify(process.env.NODE_ENV)%0A      %7D%0A    %7D)%0A  %5D,%0A
   module

Attach NODE_ENV to bundle using webpack DefinePlugin