<commit_before>/* eslint global-require: 0, import/no-dynamic-require: 0 */

/**
 * Build config for development electron renderer process that uses
 * Hot-Module-Replacement
 *
 * https://webpack.js.org/concepts/hot-module-replacement/
 */

import path from "path";
import fs from "fs";
import webpack from "webpack";
import chalk from "chalk";
import merge from "webpack-merge";
import { spawn, execSync } from "child_process";
import ExtractTextPlugin from "extract-text-webpack-plugin";
import baseConfig from "./webpack.config.base";

const port = process.env.PORT || 1212;
const publicPath = `http://localhost:${port}/dist`;
const dll = path.resolve(process.cwd(), "dll");
const manifest = path.resolve(dll, "vendor.json");

/**
 * Warn if the DLL is not built
 */
if (!(fs.existsSync(dll) && fs.existsSync(manifest))) {
  console.log(chalk.black.bgYellow.bold(
    "The DLL files are missing. Sit back while we build them for you with "npm run build-dll""
  ));
  execSync("npm run build-dll");
}

export default merge.smart(baseConfig, {
  devtool: "inline-source-map",

  target: "electron-renderer",

  entry: [
    "react-hot-loader/patch",
    `webpack-dev-server/client?http://localhost:${port}/`,
    "webpack/hot/only-dev-server",
    path.join(__dirname, "app/index.js"),
  ],

  output: {
    publicPath: `http://localhost:${port}/dist/`
  },

  module: {
    rules: [
      {
        test: /\.global\.css$/,
        use: [
          {
            loader: "style-loader"<commit_msg>Se corrigue error en el formato del log<commit_after>/* eslint global-require: 0, import/no-dynamic-require: 0 */

/**
 * Build config for development electron renderer process that uses
 * Hot-Module-Replacement
 *
 * https://webpack.js.org/concepts/hot-module-replacement/
 */

import path from "path";
import fs from "fs";
import webpack from "webpack";
import chalk from "chalk";
import merge from "webpack-merge";
import { spawn, execSync } from "child_process";
import ExtractTextPlugin from "extract-text-webpack-plugin";
import baseConfig from "./webpack.config.base";

const port = process.env.PORT || 1212;
const publicPath = `http://localhost:${port}/dist`;
const dll = path.resolve(process.cwd(), "dll");
const manifest = path.resolve(dll, "vendor.json");

/**
 * Warn if the DLL is not built
 */
if (!(fs.existsSync(dll) && fs.existsSync(manifest))) {
  console.log(chalk.black.bgYellow.bold(
    "The DLL files are missing. Sit back while we build them for you with \"npm run build-dll\""
  ));
  execSync("npm run build-dll");
}

export default merge.smart(baseConfig, {
  devtool: "inline-source-map",

  target: "electron-renderer",

  entry: [
    "react-hot-loader/patch",
    `webpack-dev-server/client?http://localhost:${port}/`,
    "webpack/hot/only-dev-server",
    path.join(__dirname, "app/index.js"),
  ],

  output: {
    publicPath: `http://localhost:${port}/dist/`
  },

  module: {
    rules: [
      {
        test: /\.global\.css$/,
        use: [
          {
            loader: "style-loader"
{'fraction_non_alphanumeric': 0.1612690019828156, 'fraction_numerical': 0.0039656311962987445, 'mean_word_length': 3.4514705882352943, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 2, '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': '7635484', 'n_tokens_mistral': 1010, 'n_tokens_neox': 959, 'n_words': 244}