<commit_before>import 'dotenv-extended/config';
import {HotModuleReplacementPlugin} from 'webpack';
import HtmlWebpackPlugin from 'html-webpack-plugin';
import BabiliPlugin from 'babili-webpack-plugin';

export default env => {
  const plugins = [
    new HotModuleReplacementPlugin(),
    new HtmlWebpackPlugin({
      template: './client/index.html'
    })
  ];

  if (env === 'production') {
    plugins.push(new BabiliPlugin());
  }

  return {
    entry: {
      main: './client/index.js'
    },
    output: {
      path: '/dist/client',
      filename: './[name].[hash].js'
    },
    module: {
      rules: [
        {
          test: /\.css$/,
          use: ['style-loader', 'css-loader']
        },
        {
          test: /\.js$/,
          use: ['babel-loader'],
          exclude: /node_modules/
        },
        {<commit_msg>feat(source-map): added source map to the webpack.config<commit_after>import 'dotenv-extended/config';
import {HotModuleReplacementPlugin} from 'webpack';
import HtmlWebpackPlugin from 'html-webpack-plugin';
import BabiliPlugin from 'babili-webpack-plugin';

export default env => {
  const plugins = [
    new HotModuleReplacementPlugin(),
    new HtmlWebpackPlugin({
      template: './client/index.html'
    })
  ];

  if (env === 'production') {
    plugins.push(new BabiliPlugin());
  }

  return {
    entry: {
      main: './client/index.js'
    },
    output: {
      path: '/dist/client',
      filename: './[name].[hash].js'
    },
    devtool: env === 'production' ? 'source map' : 'eval-source-map',
    module: {
      rules: [
        {
          test: /\.css$/,
          use: ['style-loader', 'css-loader']
        },
        {
          test: /\.js$/,
          use: ['babel-loader'],
          exclude: /node_modules/
        },
        {
{'fraction_non_alphanumeric': 0.16342412451361868, 'fraction_numerical': 0.0, 'mean_word_length': 2.1358885017421603, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, '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': '3184885', 'n_tokens_mistral': 570, 'n_tokens_neox': 553, 'n_words': 116}