G
G
Genri_Rus2022-04-16 17:27:32
Node.js
Genri_Rus, 2022-04-16 17:27:32

How to install packages compatible with node version?

Is there a workaround for installing npm packages based on the version of node on the machine?

Or maybe you can somehow find out the version of the package that will be supported, taking into account the version of node on the computer?

I tried to specify the following setting in package.json:

"engines": {
    "node": "<=8.12.0"
},

But npm doesn't install the right version packages for the current node.
How can I automatically install or find out the right version of a package for the current version of node on my computer?

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question