Joff
Joff

Reputation: 12197

how to resolve 'yarn package has unmet peer dependency'

I get a load of warnings when I run yarn upgrade or install because of unmet peerDependencies.

warning " > [email protected]" has unmet peer dependency "graphql@^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0".
warning " > [email protected]" has unmet peer dependency "@babel/core@^7.0.0".

As I understand it, the listed packages need the dependency, and another package in my project has the dependency, I can find the deps but I can't find any information about how to direct the said packages to the sub dependency that I know exists.

How can I get yarn to quiet down and show it where these deps are?

Upvotes: 30

Views: 20180

Answers (1)

Andrea Carraro
Andrea Carraro

Reputation: 10489

Both warnings are about peer dependencies, which means that it's your application's responsibility to provide those packages as dependencies.

In this case graphql and @babel/core are expected to be installed in your root app.

Upvotes: 43

Related Questions