DEV Community

siddharth jaiswal
siddharth jaiswal

Posted on

Could not resolve "zone.js"

[ERROR] Could not resolve "zone.js"

angular:polyfills:angular:polyfills:1:7:
  1 │ import 'zone.js';
    ╵        ~~~~~~~~~
Enter fullscreen mode Exit fullscreen mode

The Yarn Plug'n'Play manifest forbids importing "zone.js" here because it's not listed as a dependency of this package:

../../.pnp.cjs:36:31:
  36 │         "packageDependencies": [\
     ╵                                ~~
Enter fullscreen mode Exit fullscreen mode

You can mark the path "zone.js" as external to exclude it from the bundle, which will remove this error and leave the unresolved path in the bundle.

I am getting the above error every time I run the new angular project, Can anyone help me?

Top comments (0)