Mohit Sharma
Mohit Sharma

Reputation: 677

getting error while installing the yarn in react js project

$ yarn install
yarn install v1.19.1
warning package-lock.json found. Your project contains lock files generated by tools other than Yarn. It is advised not to mix package managers in order to avoid resolution inconsistencies cau
sed by unsynchronized lock files. To clear this warning, remove package-lock.json.
[1/5] Validating package.json...
error [email protected]: The engine "node" is incompatible with this module. Expected version ">=10.17.0". Got "10.15.2"
error Found incompatible module.
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.

getting the errors while installing the yarn in react js project

error [email protected]: The engine "node" is incompatible with this module. Expected version ">=10.17.0". Got "10.15.2"
error Found incompatible module.

Upvotes: 1

Views: 6544

Answers (2)

Tiago Gouvêa
Tiago Gouvêa

Reputation: 16740

When working on a team, sometimes another dev installs it. One good way to avoid this happening is using package-locks-checks, which I wrote.

If you run npx package-locks-checks it will check for this kind of inconsistencies and avoid you to have issues on production environment.

Upvotes: 0

demkovych
demkovych

Reputation: 8817

Remove package-lock.json and run yarn install --ignore-engines

Upvotes: 4

Related Questions