DEV Community

Hammad Hassan
Hammad Hassan

Posted on • Updated on

Html Webpack Plugin: Error: Child compilation failed: (in Reactjs)

So yesterday, I was building some application in react and initially my application was just working fine but when I installed material UI framework with its npm command, npm install @material-ui/core, I got the error Html Webpack Plugin: Error: Child compilation failed: with so many other errors were showing.

I started to google this error and got just a few posts about it and no solution helped me. I also posted my question on StackOverflow (https://stackoverflow.com/questions/59144633/i-am-getting-an-error-of-html-webpack-plugin-in-reactjs/59145436#59145436) and someone suggested to update core-js-compat npm package.

Before implementing that suggestion I found out my Node.js version is 12.13.0 and version 12.13.1 is already released. So, I just updated my Node.js and my application is now working just fine and this error has been removed.

So, If you ever get this error while building your react application you should check your Node version and update it to its latest version. Thank You

Top comments (0)