Node.js/npm/依赖检查:修订间差异
来自康健生活
| 第11行: | 第11行: | ||
{{shc|<syntaxhighlight lang="bash"> | {{shc|<syntaxhighlight lang="bash"> | ||
npm outdated</syntaxhighlight>|$|/home/kangkk}} | npm outdated</syntaxhighlight>|$|/home/kangkk}} | ||
{{shc|<syntaxhighlight lang="bash"> | |||
npm update</syntaxhighlight>|$|/home/kangkk}} | |||
{{shc|<syntaxhighlight lang="bash"> | |||
npm upgrade</syntaxhighlight>|$|/home/kangkk}} | |||
除了原生的 npm 命令之外,可以安装 cli 工具 npm-check-updates {{Version date|18.0.1|2025-4-24}} 对依赖进行更细致的分析。 | |||
{{shc|<syntaxhighlight lang="bash"> | |||
npm install -g npm-check-updates</syntaxhighlight>|$|/home/kangkk}} | |||
== 依赖清理 == | == 依赖清理 == | ||