node.js - 如何列出我与 npm 链接的所有 Node.js 模块

标签 node.js npm

我正在寻找一个命令,该命令将列出我 npm 链接'd 到本地副本的全局模块的名称,同时列出本地路径。

事实上,所有全局安装的模块列表会更好,npm 链接的那些标记不知何故。

最佳答案

要列出所有全局链接的模块,这可行(文档 https://docs.npmjs.com/cli/ls):

npm ls -g --depth=0 --link=true

不过,我必须先更新我机器上的 npm 版本:

npm install npm@latest -g

关于node.js - 如何列出我与 npm 链接的所有 Node.js 模块,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/24933955/

相关文章:

node.js - npm "scripts": "start" run express and open url

node.js - 在Elasticsearch上按顺序重新索引和删除

node.js - 在node.js中使用passport.js登录Twitter不起作用

node.js - 已弃用的正文解析器?

android - @angular/core@2.0.0-rc.1 包不满足其 sibling 的 peerDependencies 要求!

npm - Azure 管道 "Cache@2"失败并显示 "##[error]The system cannot find the file specified"

node.js 模块路径

node.js - 如何让 Grunt Deploy 使用全局 NPM 模块而不是本地模块

javascript - 在连接数据库的函数中使用app.get - NodeJs

javascript - Express:有必要用status 200响应吗?