- Use only
npm
for running scripts, in order to avoid some unexpected conflicts with different.lock
files; - Run
npm i
command to install project dependencies; - Run
npm run start
to start Storybook and review components.
Note: before publishing packages, you must have npm account and setup organization in order to publish scoped packages.
- Build components by running
npm run build:components
command; - Publish components by running
npm run publish:components
command.
- Update the package.json version for the package to be publish
- Merge into
master
- Create new component under
packages
directory; - Every component must have directory in
packages
with all of the source code. Includeindex.js
file in order to avoid specific file path import declaration; - Each component must include
package.json
file, and should include.npmignore
,CHANGELOG.md
,LICENSE
,README.md
files; - When using imports from other components use their
package.json
name and include that name and specific path to aliases under /configs/aliases.config.js; - In order to check if published component works, add dependency to root
package.json
file, runnpm i
command and comment specific alias. Run storybook and test it.