storybook
Install node modules dependencies
make install
Run storybook
make start
package
yarn package
publish
yarn publish
Auto Publish
We should tag all future PRs with one of the labels: major
, minor
, patch
, skip-release
, prerelease
, internal
, documentation
before merging them.
Working on CWS Components
To work locally on CWS-Components
without having to publish versions along the development, clone the project as a sibling of your main project. Then in cws-front
run yarn cmd:components:start
to copy the local version of cws-components
inside cws-front
(in src/cws-components
). You can then do any modifications directly in cws-front
. When your work is done, run yarn copy-components
to apply these modifications in cws-components
and yarn reset-dev-components
to reset cws-front
. You can also use yarn dev:components:watch
so the modifications on cws-components
are directly applied on cws-front
.
Hotfix
To hotfix a previous version of the cws-components
library, create a branch from the tag you want to patch (x.y.z
) named release-x.y.z+1
E.g. if you want to patch the tag 0.10.80
: you need to create a branch from the tag 0.10.80
and name it release-0.10.81
: git checkout -b release-0.10.81 v0.10.80
.
Change the version
in the package.json
so it matches the version you want to patch: 0.10.80
in our example.
Apply your fixes.
Push the branch to origin. If the tests pass, the new tag will be automatically created (but without any notification on Github).
The branch can be deleted then.
If you want the fixes to also be applied on the current version, a new branch with the classic process is needed.