Installing multiple npm versions

后端 未结 3 2045
说谎
说谎 2021-02-12 12:59

Is it possible to install multiple versions of npm for different projects that I am working on or are the npm installations always global? (Windows 10)

相关标签:
3条回答
  • 2021-02-12 13:30

    You also can install npm using npm

    Example of installing specific version:

    npm i -g npm@3.5.4

    0 讨论(0)
  • 2021-02-12 13:40

    You can install multiple versions of npm by installing multiple versions of node. To do this, you can use nvm-windows. Each different installation of node installs a different version of npm

    To use a different version of node and nvm in a project, you simple need to switch:

    nvm use 5.0
    

    You can also create a .nvmrc file containing the version number in the project root directory. nvm will use the specified version of node for that project.

    0 讨论(0)
  • 2021-02-12 13:43

    if you are using eclipse IDE for Node projects, you can easily change Node version using Webclipse plugin.

    0 讨论(0)
提交回复
热议问题