Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
import ExtractCssChunksPlugin from 'extract-css-chunks-webpack-plugin';
import OptimizeCSSAssetsPlugin from 'optimize-css-assets-webpack-plugin';
import WriteFilePlugin from 'write-file-webpack-plugin';
import createStyledComponentsTransformer from 'typescript-plugin-styled-components';
import { Configuration } from 'webpack';
import { spawn } from 'child_process';
export const devMode = process.env.NODE_ENV === 'development' ? 'development' : 'production';
process.env.isOpen = "false";
let electronProcess;
export const scTransformer = createStyledComponentsTransformer({
minify: true,
displayName: devMode == 'development',
});
export const baseConfig: Configuration = {
output: {
path: path.resolve(__dirname, 'build'),
filename: '[name].js',
publicPath: '',
},
mode: devMode,
node: {
__dirname: false,
__filename: false,
},
resolve: {