npm publish显示如下错误
错误1:
no_perms Private mode enable, only admin can publish this module
原因:由于设置为了淘宝镜像导致
解决方法如下:
npm config set registry http://registry.npmjs.org/
错误2:
403 Forbidden - PUT http://registry.npmjs.org/vue-simple-chat - Forbidden
npm ERR! 403 In most cases, you or one of your dependencies are requesting
npm ERR! 403 a package version that is forbidden by your security policy.
原因:未验证邮箱
解决方法:可重新注册账号后,npm登录后,单击顶部邮箱验证提示;登录邮箱,进行邮箱验证;以新账号登录npm进行发布
网友评论