有没有办法在 npm 上更改包的最新版本

Is there a way to change the latest version of a package on npm

因此,例如,我制作了一个包并发布了版本 1.0.0

但是后来,我决定将包的版本更改为 0.1.0 并添加默认标签 latest

我该怎么做?

在package.json中,您需要更新版本,然后使用属性--tag=latest 发布包。所以语法将变成: npm publish --tag=latest.