npm Requires a peer but none was installed

Viewed 12634

I am getting the following warnings but i didn´t figure out how to update them. I also have tried to install the dependencies needed but it does not work.

npm WARN ajv-keywords@2.1.0 requires a peer of ajv@>=5.0.0 but none was installed.
npm WARN ionic2-super-tabs@2.6.3 requires a peer of ionic-angular@^3.4.0 but none was installed.
npm WARN ng2-translate@5.0.0 requires a peer of @angular/core@^2.0.0 but none was installed.
npm WARN ng2-translate@5.0.0 requires a peer of @angular/http@^2.0.0 but none was installed.

Could you please help me?

Best regards.

4 Answers

I think it is possible that you did install the dependencies. For me, I get a similar

npm WARN react-addons-test-utils@15.6.2 requires a peer of react-dom@^15.4.2 but none is installed. You must install peer dependencies yourself.

but I already have react-dom@^16. I believe it is because in your package.json you may have one dependency in devDependencies and the others in dependencies. Note differences in --save-dev and --save.

In my case the library was not installed, so I Google "npm ajv", in the npm web page I when to the Install box and copy the content "npm i ajv", then I open Powershell on the root directory of my Angular project and run the command. This added the library to my project and solved the issue.

Related