Useful for any backend or frontend JavaScript or TypeScript project.
yarn add @binary-owls/sdk-node
First, it's easiest to use the Jetbrains Debugger to run individual unit tests.
But you can also test via CLI:
yarn test
To locally develop the package, install Yalc:
yarn global add yalc
Then we can publish this package locally:
cd sdk-node
yalc publish
In the implementing project:
yalc add @binary-owls/sdk-node
# Log in to npmjs.org
npm login
# NOTE the built files is the main publication, not the TS source
yarn build
# 1. Edit version in package.json
# 2. Run publish
# NOTE: yarn publish has issues with auto-committing, and running `npm publish` as a yarn command also has issues, so we need to just run this raw:
npm publish --access public
# You will be prompted for the new semver.
# Then if publication is successful, package.json will automatically have its `"version"` updated
git add --all
git commit
Optional:
# Remove a specific package version
npm unpublish @binary-owls/sdk-node@0.1.0