var webpack = require('webpack');
var development = process.env.NODE_ENV !== "production";

var PATHS = {
  BUILD: __dirname + '/dist',
  APP: __dirname + '/src'
}

module.exports = {
  context: __dirname,
  devtool: development ? "inline-sourcemap" : null,
  entry: PATHS.APP + "/script.jsx",
  output: {
    path: PATHS.BUILD,
    filename: "scripts.js"
  },
  module : {
    loaders : [
      {
        test : /\.jsx?/,
        include : PATHS.APP,
        loader : 'babel'
      }
    ]
  },
  plugins: development ? [] : [
    new webpack.optimize.DedupePlugin(),
    new webpack.optimize.OccurenceOrderPlugin(),
    new webpack.optimize.UglifyJsPlugin({ mangle: false, sourcemap: false }),
  ],
};
var webpack = require('webpack');
var development = process.env.NODE_ENV !== "production";
var path = require('path');

var PATHS = {
  BUILD: path.join(__dirname, '..', 'example_site/public'),
  APP: __dirname + '/src'
}

module.exports = {
  context: __dirname,
  devtool: development ? "inline-sourcemap" : null,
  entry: PATHS.APP + "/script.jsx",
  output: {
    path: PATHS.BUILD,
    filename: "scripts.js"
  },
  module : {
    loaders : [
      {
        test : /\.jsx?/,
        include : PATHS.APP,
        loader : 'babel'
      }
    ]
  },
  plugins: development ? [] : [
    new webpack.optimize.DedupePlugin(),
    new webpack.optimize.OccurenceOrderPlugin(),
    new webpack.optimize.UglifyJsPlugin({ mangle: false, sourcemap: false }),
  ],
};
Configure webpack to spit `scripts.js` into the "example_site".
Configure webpack to spit `scripts.js` into the "example_site".

This is a temporary solution to make the dev experience a bit cleaner. Until we figure out if / where the example-site should live / be committed, webpack will look to spit out the bundle up a director, into "example_site//public"
