@abbeblubb/react-library 中文文档教程
Publish the library to NPM
Miscellaneous
Babel
由于根上下文,本地 babel 配置的名称应该是“babel.config.json”。
package.json peerDependencies
为了为消费者工作,
Build the library
使用 Webpack 构建。
> npm run build:lib
Sign in to NPM
> npm adduser
First publish
第一次发布范围包时,必须添加公共访问标志才能使包公开。
> npm publish --access=public
Subsequent publishes
- Update the SemVer in package.json
- Push to registry
> npm publish
Publish the library to NPM
Miscellaneous
Babel
Because of the root context, the name of the local babel config should be "babel.config.json".
package.json peerDependencies
In order to work for the consumer
Build the library
Build with Webpack.
> npm run build:lib
Sign in to NPM
> npm adduser
First publish
The first time a scope package is to be published, the public acces flag must be added in order for the package to be public.
> npm publish --access=public
Subsequent publishes
- Update the SemVer in package.json
- Push to registry
> npm publish