NPM安装后无法导入单个软件包,也未出现在列表中

时间:2019-06-05 18:49:05

标签: npm npm-install

对于我安装的每个软件包,它都能完美安装并添加到我的依赖项中。但是,当我尝试使用它或将其导入到我的代码中时,却找不到单个部分。当我执行npm list时,它也不在我的列表中。 它确实显示在我的资源管理器的module文件夹中。我一直在寻找一种解决方案,现在已经3个小时了。 我尝试了所有发现的stackoverflow解决方案,但没有任何效果。删除了文件夹,重新进行了安装,初始化等操作。尝试了不同的软件包。似乎没有任何作用。 任何帮助表示赞赏。

谢谢

ERROR in ./node_modules/request/lib/har.js
Module not found: Error: Can't resolve 'fs' in ' 
D:\Eigen\PlexRequest\node_modules\request\lib'
@ ./node_modules/request/lib/har.js 3:9-22
@ ./node_modules/request/request.js
@ ./node_modules/request/index.js
@ ./node_modules/imdb/lib/movies.js
@ ./node_modules/imdb/lib/imdb.js
@ ./node_modules/imdb/index.js
@ ./src/app.js

ERROR in ./node_modules/forever-agent/index.js
Module not found: Error: Can't resolve 'net' in 

'D:\Eigen\PlexRequest\node_modules\forever-agent'
 @ ./node_modules/forever-agent/index.js 6:10-24
 @ ./node_modules/request/request.js
 @ ./node_modules/request/index.js
 @ ./node_modules/imdb/lib/movies.js
 @ ./node_modules/imdb/lib/imdb.js
 @ ./node_modules/imdb/index.js
 @ ./src/app.js

ERROR in ./node_modules/tough-cookie/lib/cookie.js
Module not found: Error: Can't resolve 'net' in 'D:\Eigen\PlexRequest\node_modules\tough-cookie\lib'
 @ ./node_modules/tough-cookie/lib/cookie.js 32:10-24
 @ ./node_modules/request/lib/cookies.js
 @ ./node_modules/request/index.js
 @ ./node_modules/imdb/lib/movies.js
 @ ./node_modules/imdb/lib/imdb.js
 @ ./node_modules/imdb/index.js
 @ ./src/app.js

ERROR in ./node_modules/tunnel-agent/index.js
Module not found: Error: Can't resolve 'net' in 'D:\Eigen\PlexRequest\node_modules\tunnel-agent'
 @ ./node_modules/tunnel-agent/index.js 3:10-24
 @ ./node_modules/request/lib/tunnel.js
 @ ./node_modules/request/request.js
 @ ./node_modules/request/index.js
 @ ./node_modules/imdb/lib/movies.js
 @ ./node_modules/imdb/lib/imdb.js
 @ ./node_modules/imdb/index.js
 @ ./src/app.js

ERROR in ./node_modules/forever-agent/index.js
Module not found: Error: Can't resolve 'tls' in 'D:\Eigen\PlexRequest\node_modules\forever-agent'
 @ ./node_modules/forever-agent/index.js 7:10-24
 @ ./node_modules/request/request.js
 @ ./node_modules/request/index.js
 @ ./node_modules/imdb/lib/movies.js
 @ ./node_modules/imdb/lib/imdb.js
 @ ./node_modules/imdb/index.js
 @ ./src/app.js

ERROR in ./node_modules/tunnel-agent/index.js
Module not found: Error: Can't resolve 'tls' in 'D:\Eigen\PlexRequest\node_modules\tunnel-agent'
 @ ./node_modules/tunnel-agent/index.js 4:10-24
 @ ./node_modules/request/lib/tunnel.js
 @ ./node_modules/request/request.js
 @ ./node_modules/request/index.js
 @ ./node_modules/imdb/lib/movies.js
 @ ./node_modules/imdb/lib/imdb.js
 @ ./node_modules/imdb/index.js
 @ ./src/app.js

0 个答案:

没有答案