Module build failed (from ./node_modules/@ngtools/webpack/src/ivy/index.js)

While running a angular 10 project I was facing the error

Module build failed (from ./node_modules/@ngtools/webpack/src/ivy/index.js):

I solved the error by updating angular core and cli to 11.0.5

ng update @angular/core@11.0.5 @angular/cli@11.0.5
ng update

 

reference: https://stackoverflow.com/questions/65849026/errors-after-npm-audit-fix-angular-10-0-1

 

Add comment