diff --git a/ui/config-overrides.js b/ui/config-overrides.js index aa32857fc8..a0cff4eb62 100644 --- a/ui/config-overrides.js +++ b/ui/config-overrides.js @@ -27,9 +27,19 @@ const setWebpackPerformance = () => (config) => { return config; }; +/** + * After getting a lot of OOM issues while building the UI, we disabled terser parallelism + * Refs: https://github.com/timarney/react-app-rewired/issues/391#issuecomment-571954944 + */ +const terserDisableParallelism = () => config => { + config.optimization.minimizer[0].parallel=false; + return config; +}; + module.exports = override( useBabelRc(), useEslintRc(), addWebpackPlugin(new CompressionPlugin()), setWebpackPerformance(), + terserDisableParallelism() );