const path = require('path')
const HtmlWebpackPlugin = require('html-webpack-plugin')

const HtmlWebpackPluginConfig = new HtmlWebpackPlugin({
  template: './index.html',
  filename: 'index.html',
  inject: 'body'
})

var config = {
  context: path.resolve(__dirname, 'src'),
  entry: {
    index: './index.js'
  },
  output: {
    path: path.resolve(__dirname, 'dist'),
    publicPath: '/',
    filename: 'bundle.js'
  },
  devtool: 'source-map',
  resolve: {
    extensions: ['.js', '.jsx']
  },
  module: {
    loaders: [
      {
        test: /\.jsx?$/,
        loader: 'babel-loader',
        exclude: /node_modules/
      },
      {
        test: /\.scss$/,
        loader: 'style-loader!css-loader!sass-loader'
      }
    ]
  },
  plugins: [HtmlWebpackPluginConfig]
}

module.exports = config

@@ -1,12 +1,47 @@
+const webpack = require('webpack')%0A
 const path =
@@ -57,16 +57,16 @@
 'path')%0A
-
 const Ht
@@ -334,24 +334,70 @@
 './index.js'
+,%0A    header: './components/Header/Header.jsx'
 %0A  %7D,%0A  outp
@@ -481,16 +481,23 @@
 ename: '
+%5Bname%5D.
 bundle.j
@@ -830,16 +830,21 @@
 ugins: %5B
+%0A    
 HtmlWebp
@@ -858,16 +858,120 @@
 inConfig
+,%0A    new webpack.optimize.CommonsChunkPlugin(%7B name: 'common' %7D) //prevent duplicate imports across %0A  
 %5D%0A%7D%0A%0Amod

add bundle splitting