<commit_before>const {
  DefinePlugin,
  HotModuleReplacementPlugin,
  NoErrorsPlugin,
  optimize,
} = require('webpack');
const { OccurenceOrderPlugin, UglifyJsPlugin } = optimize;
const path = require('path');
const autoprefixer = require('autoprefixer');
const env = process.env.NODE_ENV || 'development';
const isDev = env === 'development';

const defineConstPlugin = new DefinePlugin({
  __DEV__: isDev,
});

module.exports = {
  devtool: isDev ? 'cheap-module-eval-source-map' : 'source-map',

  entry: isDev ? [
    'babel-polyfill',
    'webpack-hot-middleware/client',
    './src/index',
  ] : [
    'babel-polyfill',
    './src/index',
  ],

  output: {
    path: path.join(__dirname, 'dist', 'static'),
    filename: 'bundle.js',
    publicPath: '/static/',
  },

  plugins: isDev ? [
    defineConstPlugin,
    new HotModuleReplacementPlugin(),
    new NoErrorsPlugin(),
  ] : [
    defineConstPlugin,
    new OccurenceOrderPlugin(),
    new UglifyJsPlugin({
      compressor: { warnings: false },
    }),
  ],

  module: {
    loaders: [{
      test: /\.js$/,
      loaders: [ 'babel' ],
      include: path.join(__dirname, 'src'),
    }, {
      test: /\.css$/,
      loaders: [
        'style-loader',
        'css-loader?modules&localIdentName=[name]__[local]__[hash:base64:5]',<commit_msg>destructuring in webpack.config.js broke the build<commit_after>const webpack = require('webpack');
const path = require('path');
const autoprefixer = require('autoprefixer');
const env = process.env.NODE_ENV || 'development';
const isDev = env === 'development';

const defineConstPlugin = new webpack.DefinePlugin({
  __DEV__: isDev,
});

module.exports = {
  devtool: isDev ? 'cheap-module-eval-source-map' : 'source-map',

  entry: isDev ? [
    'babel-polyfill',
    'webpack-hot-middleware/client',
    './src/index',
  ] : [
    'babel-polyfill',
    './src/index',
  ],

  output: {
    path: path.join(__dirname, 'dist', 'static'),
    filename: 'bundle.js',
    publicPath: '/static/',
  },

  plugins: isDev ? [
    defineConstPlugin,
    new webpack.HotModuleReplacementPlugin(),
    new webpack.NoErrorsPlugin(),
  ] : [
    defineConstPlugin,
    new webpack.optimize.OccurenceOrderPlugin(),
    new webpack.optimize.UglifyJsPlugin({
      compressor: { warnings: false },
    }),
  ],

  module: {
    loaders: [{
      test: /\.js$/,
      loaders: [ 'babel' ],
      include: path.join(__dirname, 'src'),
    }, {
      test: /\.css$/,
      loaders: [
        'style-loader',
        'css-loader?modules&localIdentName=[name]__[local]__[hash:base64:5]',
{'fraction_non_alphanumeric': 0.16757176105508145, 'fraction_numerical': 0.0023273855702094647, 'mean_word_length': 3.179902755267423, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7441572', 'n_tokens_mistral': 885, 'n_tokens_neox': 865, 'n_words': 157}