Skip to content

Contributing

Routa is open source under the MIT License. The repository is a pnpm workspace holding three published packages, two example applications, and this documentation site, wired together with Turborepo.

  • Node.js 24 or later, matching .nvmrc.
  • pnpm. The repository uses workspace protocol links between packages.
  • A read of the v0 requirements and current public scope. Maintainers coordinate planned V1 work through the project-local tracker described in docs/agents/issue-tracker.md.
  1. Install dependencies from the repository root.

    Terminal window
    pnpm install
  2. Run the full check suite before making changes, so you know the baseline is green.

    Terminal window
    pnpm check
    pnpm typecheck
    pnpm build
    pnpm test

    pnpm check runs Biome formatting and lint checks. The other three run through Turborepo across every workspace package.

  3. Make the change in the package that owns the behavior.

    Path Owns
    packages/core Route, middleware, config, logger, and query helpers
    packages/cli Validation, generation, OpenAPI, scaffolding, and the servers
    packages/create-routa-ts The project scaffolder
    apps/docs This documentation site
    examples/* Runnable demonstrations of the public surface
  4. Verify against a real project. The examples run the routa binary, so build and link the local CLI before checking them.

    Terminal window
    pnpm prepare:local-cli
    pnpm --filter full-api check
    pnpm --filter full-api dev
  5. Add a changeset for any change to a published package.

    Terminal window
    pnpm changeset
  6. Update the documentation in the same pull request. Read apps/docs/AGENTS.md first; it defines the required page frame, the package-manager command component, and the structure each section uses.

pnpm verify runs the complete gate: lint, typecheck, tests, generated-file drift, example checks, OpenAPI checks, the scaffold error smoke test, and a packaging check. A change is ready when it passes and the docs site builds.

Terminal window
pnpm verify
pnpm --filter @routa-ts/docs build

Every new feature needs all four of these, which is what the coverage rules in apps/docs/AGENTS.md enforce:

  • A reference entry with its signature, options, and one example.
  • A mention in at least one guide showing it in a real workflow.
  • An entry in Diagnostics for any new ROUTA_* code.
  • A line in the implemented table on v0 Scope & Status.
Problem Fix
Workspace packages resolve to published versions Run pnpm install from the root, not from inside a package.
An example fails after a core change Rebuild first. Examples consume built output, so run pnpm build.
Biome reports formatting differences Run pnpm format to apply them.
The docs build fails on a slug A sidebar entry in astro.config.mjs points at a page that does not exist.