Npm install cannot find module 'semver'

后端 未结 26 1484
南方客
南方客 2020-11-29 15:29

I can\'t use npm install using the command prompt in NodeJS. I\'m getting these errors when running npm install:

module.js:339
             


        
26条回答
  •  再見小時候
    2020-11-29 16:05

    This worked for me on Ubuntu (latest version dated Oct/2020)

    I had to first get code from the bash source:

    curl -sL https://deb.nodesource.com/setup_14.x | sudo -E bash -
    

    This got the latest version of node which updated my libraries and got rid of the 'semver' error.

提交回复
热议问题