[英]NPM throw err 491
I have just installed node hence i run the node -v and npm -v
to confirm that they have successfully been installed. 我刚刚安装了节点,因此我运行
node -v and npm -v
来确认它们已成功安装。 node -v
is returning the version of node as expected, however npm -v
throws the bellow error. node -v
返回了预期的节点版本,但是npm -v
引发了以下错误。 What can be the issue? 可能是什么问题?
module.js:491
throw err;
^
Error: Cannot find module '../lib/utils/unsupported.js'
at Function.Module._resolveFilename (module.js:489:15)
at Function.Module._load (module.js:439:25)
at Module.require (module.js:517:17)
at require (internal/module.js:11:18)
at /usr/local/lib/node_modules/npm/bin/npm-cli.js:19:21
at Object.<anonymous> (/usr/local/lib/node_modules/npm/bin/npm-
cli.js:92:3)
at Module._compile (module.js:573:30)
at Object.Module._extensions..js (module.js:584:10)
at Module.load (module.js:507:32)
at tryModuleLoad (module.js:470:12)`
It might be a permissions problem, delete your local/lib/node_modules folder and reinstall node. 可能是权限问题,请删除您的local / lib / node_modules文件夹并重新安装节点。 For further info, you might wanna check out this error resolved on npm's github discussion .
有关更多信息,您可能想查看npm的github讨论上解决的此错误。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.