简体   繁体   English

npm 安装错误:找不到模块“read-package-tree”

[英]npm install error: cannot find module 'read-package-tree'

executing the npm install command in windows 10 machine.在 windows 10 机器上执行 npm 安装命令。

facing the below issue面对以下问题

C:\ >npm install
npm ERR! code MODULE_NOT_FOUND
npm ERR! Cannot find module 'read-package-tree'
npm ERR! Require stack:
npm ERR! - C:\Users\dineshkumars2\AppData\Roaming\npm\node_modules\npm\lib\install.js
npm ERR! - C:\Users\dineshkumars2\AppData\Roaming\npm\node_modules\npm\lib\npm.js
npm ERR! - C:\Users\dineshkumars2\AppData\Roaming\npm\node_modules\npm\bin\npm-cli.js

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\dineshkumars2\AppData\Roaming\npm-cache\_logs\2020-12-31T02_21_08_042Z-debug.log

Try installing read-package-tree using npm command as,尝试使用 npm 命令安装read-package-tree

npm i read-package-tree

In case same error showing for executing the above command, Please copy the folder from another machine and paste it into the path that where node_modules are in.如果执行上述命令显示相同的错误,请从另一台机器复制文件夹并将其粘贴到node_modules所在的路径中。

Ex:前任:

C:\Users\MyName\AppData\Roaming\npm\node_modules\npm\node_modules

then run the below command npm i read-package-tree it will resolve the issue, now we can able to run the command 'npm install'然后运行以下命令npm i read-package-tree它将解决问题,现在我们可以运行命令“npm install”

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM