updating the npm package code example Example 1: npm update syntax Click to copynpm update -g Example 2: npm update syntax Click to copynpm outdated -g --depth=0