We use lerna for publishing.

lerna publish

These options are useful

lerna publish --scope cozy-client
$ lerna publish --scope cozy-client --npm-tag beta
$ npm install cozy-client@beta

⚠️ Even if you use an NPM tag, this creates a real version on NPM. If you want to create a beta version, change the version in the package.json of the package you are publishing and add for example beta.0. This way, you do not take the space of the next version.

lerna publish --scope cozy-client --force-publish cozy-client


Use yarn watch to watch on cozy-client side and yarn link on the app side.

If you have a problem like “React is not found” from cozy-client files, it may be because webpack is resolving the dependencies in cozy-client’s node_modules, you may want to ln -s your app node_modules inside cozy-client’s.

$ ls code

$ cd cozy-client/packages/cozy-client
$ rm -rf node_modules
$ ln -s ~/code/cozy-banks/node_modules .