一、js工程安装
npm install 问题{ Error: EACCES: permission denied, mkdir }
处理方案:
1) 在命令结尾加 --unsafe-perm: npm install --unsafe-perm
2) 或者在package.json中添加:
"config": {
"unsafe-perm":true
}
二、发布
npm publish
如果出现了
npm ERR! publish Failed PUT 402 npm ERR! code E402 npm ERR! You must sign up for private packages : @okexchain/javascript-sdk-qrcode npm ERR! A complete log of this run can be found in: npm ERR! /Users/path/.npm/_logs/2021-02-01T03_36_47_300Z-debug.log
则:
npm publish --access=public