In order to run the io-std
libraries locally you need the following tool installed on your machine.
Node.js 18
yarn 3
The preferred way to set up the local environment is using nodenv to manage Node.js
installation and corepack
(included with Node.js
) to manage the installation of yarn
.
This project uses changesets to automate updating package versions, and changelogs.
Each Pull Request that includes changes that require a version bump should include a changeset
file that describe that changes.
To create a new changeset
file run the following command from the project root:
yarn changeset
This project uses yarn@3
with workspaces and turborepo to manage projects and dependencies. Here is a list of useful commands to work in this repo.
# to execute COMMAND on WORKSPACE_NAME
yarn workspace WORKSPACE_NAME run command
# to execute COMMAD on all workspaces
yarn workspace foreach run command
# run unit tests on @pagopa/handler-kit
yarn workspace @pagopa/handler-kit run test
# run the typecheck script on all workspaces
yarn workspaces foreach run typecheck
# add a dependency to the workspace root
yarn add turbo
# add vitest dev dependency on @pagopa/handler-kit
yarn workspace @pagopa/handler-kit add -D vitest
# add io-ts as dependency on each workspace
yarn workspace foreach add io-ts
# builds all workspaces and their dependencies
yarn build
# build @pagopa/handler-kit and its dependencies
yarn build --filter @pagopa/handler-kit
# run the code-review script (the same as the CI)
yarn code-review