Skip to content

Add a zero-tolerance TypeDoc documentation gate#110

Draft
leynos wants to merge 2 commits into
mainfrom
typedoc-rollout
Draft

Add a zero-tolerance TypeDoc documentation gate#110
leynos wants to merge 2 commits into
mainfrom
typedoc-rollout

Conversation

@leynos

@leynos leynos commented Jul 17, 2026

Copy link
Copy Markdown
Owner

Summary

This branch adds a zero-tolerance TypeDoc documentation gate to the
test:all aggregate. TypeDoc's notDocumented validation runs over
src (entryPointStrategy: "expand") with emit: "none" and
validation warnings treated as errors: every exported declaration must
carry a JSDoc comment (unexported local helpers are not counted). The
gate reports the qualified name of each undocumented declaration,
writes no documentation artefacts, and fails on a single omission. It
is also exposed as make docs-check, and the semantic-lint workflow
gains a bun run docs:check step so CI reaches it.

The first commit documents the nineteen declarations TypeDoc flagged —
the existing Oxlint JSDoc rules had already kept the surface almost
fully documented; the second wires the gate and fixes a pre-existing
dependency problem that broke the aggregate (see notes).

Review walkthrough

Validation

  • Gate components run individually, all green: bun lint,
    bun check:types, bun run docs:check, bun test,
    bun run test:a11y, bun run lint:ftl-vars, bun run semantic,
    make spelling, and bash scripts/e2e.sh (1 passed, with the dev
    server up and tokens:build run first).
  • Mutation check: deleting the JSDoc line from the exported
    AppRoutesProps interface makes bun run docs:check exit 4 naming
    the symbol; restoring it returns the gate to green.
  • A clean docs:check run emits no files and no output.

Notes

leynos added 2 commits July 18, 2026 00:22
Prepare for a zero-tolerance TypeDoc documentation gate: add JSDoc to
the nineteen declarations TypeDoc flags across the app shell, the
display-mode provider, the observability logger, the application state
machine unions, and the root props. Reflow the state-machine union
members to multiline so each variant's discriminant can carry its own
comment (shapes unchanged), and convert the two application barrel
headers from `@file` (unknown to TypeDoc) to the `@module` form.
Add `docs:check` to the `test:all` aggregate (after `check:types`) and
expose it as `make docs-check`: TypeDoc's `notDocumented` validation
over `src` (`entryPointStrategy: "expand"`, `emit: "none"`, validation
warnings as errors), configured by `typedoc.json` with a scoped
`tsconfig.typedoc.json` (`skipLibCheck`, `src` only — the repository's
`check:types` passes `--skipLibCheck` on the command line, which
TypeDoc cannot see). Generated declarations, `*.gen.*`,
`__generated__`, tests, and fixtures are excluded. The gate requires
100% documentation of the surface, reports the qualified name of each
undocumented declaration, and writes no artefacts. The semantic-lint
workflow gains a `bun run docs:check` step so CI reaches the gate.

Also bump the stale transitive `playwright-core` from 1.59.1 to 1.61.1
so it deduplicates against `playwright@1.61.1` — the duplicated
package made `check:types` (and therefore `test:all`) fail before this
branch.

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry @leynos, you have reached your weekly rate limit of 500000 diff characters.

Please try again later or upgrade to continue using Sourcery

@coderabbitai

coderabbitai Bot commented Jul 17, 2026

Copy link
Copy Markdown

Important

Review skipped

Draft detected.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: c03f8e1c-3f3f-4bea-af76-a6d584b26689

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch typedoc-rollout

Comment @coderabbitai help to get the list of available commands.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant