Package @reatom/_media/contributing
[!NOTE] We prefer English language for all communication.
Creating an issue
Before creating an issue please ensure that the problem is not already reported.
If you want to report a bug, create a reproduction using StackBlitz or CodeSandbox. If you want to request a feature, add motivation section and some usage examples.
Sending a Pull Request
[!TODO] Update requirements for development
- fork and clone the repository
- create a development branch from
v1000 - install dependencies from the root of the repo (Node 24.2.0 and
pnpm@10.25.0are recommended):Note: this command installs dependencies for all packages, but only buildsTerminal window pnpm install@reatom/core. - build the package you are editing from the root of the repo:
Replace
Terminal window pnpm --filter <PACKAGE_NAME> run build<PACKAGE_NAME>with the relevant package name like@reatom/react - make changes and commit them
- upload feature branch and create a Pull Request to merge changes to
v1000 - link your PR to the issue using a closing keyword or provide changes description with motivation and explanation in the comment (example:
fix #74) - wait until a team member responds
Creating a package
The goal of Reatom ecosystem is to provide adapters for Web APIs and popular npm modules. Therefore, the process of creating a new package is almost identical to editing an existing one (Sending a Pull Request), but you should also create the package using an interactive script ran in the repository root:
pnpm run package-generatorAdd needed dependencies by running pnpm install in the repository root. To add a dependency to a specific package, use pnpm --filter <PACKAGE_NAME> add <LIBRARY> or update the package’s package.json and then run pnpm install from the repository root. If you’re making an adapter for a particular npm library (like @reatom/react for React), add the library as a peer dependency using pnpm --filter <PACKAGE_NAME> add --save-peer <LIBRARY>.
Coding guide
- bug fixes should also add tests that reproduce the addressed bug
- all new features should be tested and documented
- use
// @ts-ignoreif you’re not sure why an error appears or you think it’s acceptable to suppress it temporarily. Use// @ts-expect-errorif you’re certain the error is a false positive and you want TypeScript to expect it.
Commit messages
Commit messages should follow the Conventional Commits specification:
<type>[optional scope]: <description>Allowed <type>
chore: any repository maintainance changesfeat: code change that adds a new featurefix: bug fixperf: code change that improves performancerefactor: code change that is neither a feature addition nor a bug fix nor a performance improvementdocs: documentation only changesci: a change made to CI configurations and scriptsstyle: cosmetic code changetest: change that only adds or corrects testsrevert: change that reverts previous commits
Allowed <scope>
Package directory name. Eg: /packages/react is scoped as react.
<description> rules
- should be written in English
- should be in imperative mood (like
changeinsteadchangedorchanges) - should not be capitalized
- should not have period (
.) at the end
Commit message examples
docs: fix typo in reactfix(core): add check for atoms with equal ids