<commit_before>var webpack = require('webpack');
var path = require('path');
var HtmlWebpackPlugin = require('html-webpack-plugin');
var ExtractTextPlugin = new require("extract-text-webpack-plugin");

var ExtractStyles = new ExtractTextPlugin('main.css');

var host = (process.env.HOST || 'localhost');
var port = (+process.env.PORT) || 3000;

module.exports = {
  context: path.join(__dirname, './client'),
  entry: {
    jsx: './index.jsx',
    //html: './index.html',
    vendor: [
      'react',
      'react-dom',
      'react-redux',
      'react-router',
      'react-router-redux',
      'redux',
      'ramda'
    ]
  },
  output: {
    path: path.join(__dirname, './static'),
    filename: 'bundle.js',
    //prod: publicPath: 'http://' + host + ':' + port + '/ElementsBattle/'
    publicPath: 'http://' + host + ':' + port + '/'
  },
  module: {
    rules: [
      {
        test: /\.html$/,
        use: 'file-loader?name=[name].[ext]'
      },
      {
        test: /\.css$/,
        include: /client/,
        use: ExtractStyles.extract([
          'css-loader?modules&camelCase&sourceMap&importLoaders=1&localIdentName=[local]___[hash:base64:5]&minimize',
          'postcss-loader'
        ]),
      },
      {
        test: /\.css$/,
        exclude: /client/,
        use: ExtractStyles.extract({
          use: 'css-loader'
        })
      },
      {
        test: /\.(js|jsx)$/,
        exclude: /node_modules/,
        use: [
          'react-hot-loader',
          'babel-loader'<commit_msg>Do not load port in prod<commit_after>var webpack = require('webpack');
var path = require('path');
var HtmlWebpackPlugin = require('html-webpack-plugin');
var ExtractTextPlugin = new require("extract-text-webpack-plugin");

var ExtractStyles = new ExtractTextPlugin('main.css');

var host = (process.env.HOST || 'localhost');
var port = (+process.env.PORT) || 3000;

module.exports = {
  context: path.join(__dirname, './client'),
  entry: {
    jsx: './index.jsx',
    //html: './index.html',
    vendor: [
      'react',
      'react-dom',
      'react-redux',
      'react-router',
      'react-router-redux',
      'redux',
      'ramda'
    ]
  },
  output: {
    path: path.join(__dirname, './static'),
    filename: 'bundle.js',
    //prod: publicPath: 'http://' + host + ':' + port + '/ElementsBattle/'
    publicPath: 'http://' + host + ((process.env.NODE_ENV !== 'production') ? (':' + port) : '' ) + '/'
  },
  module: {
    rules: [
      {
        test: /\.html$/,
        use: 'file-loader?name=[name].[ext]'
      },
      {
        test: /\.css$/,
        include: /client/,
        use: ExtractStyles.extract([
          'css-loader?modules&camelCase&sourceMap&importLoaders=1&localIdentName=[local]___[hash:base64:5]&minimize',
          'postcss-loader'
        ]),
      },
      {
        test: /\.css$/,
        exclude: /client/,
        use: ExtractStyles.extract({
          use: 'css-loader'
        })
      },
      {
        test: /\.(js|jsx)$/,
        exclude: /node_modules/,
        use: [
          'react-hot-loader',
          'babel-loader'
{'fraction_non_alphanumeric': 0.1930164888457808, 'fraction_numerical': 0.005172971225347559, 'mean_word_length': 2.128412537917088, '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': '2438590', 'n_tokens_mistral': 1044, 'n_tokens_neox': 1012, 'n_words': 180}