Contributing to AFFiNE

Thank you for helping improve AFFiNE. Contributions can take many forms: reporting a reproducible bug, refining an idea, improving documentation or translations, writing tests, or changing code.

This page is the short contributor entry point. The AFFiNE core repository remains the source of truth for contribution rules and the current build guide.

Choose how to contribute

ContributionStart here
Report a bugSearch existing issues, then use the AFFiNE issue form. Include the affected platform, app version, reproduction steps, and useful logs or screenshots.
Propose a featureStart in GitHub Discussions so the problem and scope can be discussed before implementation.
Fix code or testsBrowse good first issues or reviewed issues, then follow the code workflow below.
Improve these docsReport a documentation problem through the public AFFiNE issue form or start a GitHub Discussion. If you maintain AFFiNE.docs, edit the repository-owned source under content-overrides/docs/, run yarn sync:content-overrides, and commit the source together with its checked-in docs/ mirror.
Improve translationsRead the current i18n package guide and coordinate through AFFiNE Discord.
Report a vulnerabilityFollow the private reporting instructions in the Security Policy. Do not open a public issue for an undisclosed vulnerability.

Before you start

  1. Read the Code of Conduct.
  2. Search issues and discussions for existing work.
  3. Avoid starting from an issue that is still in triage. For a large feature or architectural change, discuss the approach with maintainers first.
  4. Sign the Contributor License Agreement. The license/cla check must be green for every committer before a pull request can merge.

Set up the codebase

Fork and clone toeverything/AFFiNE, then add the upstream repository and create your branch from the current development branch:

git remote add upstream https://github.com/toeverything/AFFiNE.git
git fetch upstream canary
git switch -c fix/short-description upstream/canary

Use the Node version pinned in .nvmrc, enable Corepack for the Yarn version pinned by the repository, and follow the Building AFFiNE Web guide.

For other targets, use the current core guides:

Validate your change

Run the checks that cover the code you changed. The repository-level baseline is:

yarn lint
yarn typecheck
yarn test

Large test suites can be targeted by workspace; the current build guide lists the supported web, cloud, desktop, mobile, and BlockSuite suites. Add or update tests for behavior changes, and include screenshots or recordings for visible UI changes.

For AFFiNE.docs changes, run:

corepack enable
yarn install
yarn test:docs-links
yarn test:content-overrides
yarn build
yarn check:seo

Open a pull request

  1. Open AFFiNE core pull requests against canary. AFFiNE.docs pull requests use that repository's current default branch.
  2. Use a Conventional Commits title such as fix(editor): keep selection after paste or docs: refresh contributor setup.
  3. Complete the current pull request checklist, link the relevant issue or discussion, and explain how the change was tested.
  4. Allow maintainer edits when submitting from a fork.
  5. Address review comments and keep the license/cla, title, build, and test checks green.

A maintainer decides when a pull request is ready to merge. A merged change, a canary build, and a public release are separate states; do not rely on a fixed deployment time.

Get help