# CLAUDE.md — `apps/dev-tools-help-docs`

The documentation site (starterdocs.vtempest.workers.dev): Next.js + Fumadocs,
with AI chat, full-text search, and an auto-generated API reference built from
TypeScript types and OpenAPI specs.

## The one rule everyone trips on

**This is the only Biome workspace in the repo.** `check`, `lint`, `format` and
`check:write` here are Biome; nothing outside `apps/dev-tools-help-docs` is
formatted by it and there is no repo-wide formatter. Never run Biome over the
rest of the monorepo — it will rewrite files that nobody formats that way.

It also carries its own `commitlint.config.ts`, `cspell` config and
`bunfig.toml`, all scoped to this app.

## Content comes from two places

- `content/docs/` — pages written here.
- Package READMEs, pulled in by `bun run docs:sync` (root) or
  `bun ./scripts/sync-readme-docs.ts`. **Synced pages are generated** — edit the
  package README, then re-sync. Editing the synced copy is lost on the next run.

Remember the package README's own header is itself generated by
`bun run readmes`, so the chain is:
`package.json` → `.github/scripts/sync-package-readmes.mjs` → `README.md` → `docs:sync`
→ this site.

## Build is staged

```bash
bun run dev
bun run build          # bun --bun next build
bun run build:full     # build:pre → next build → build:post
bun run typecheck      # runs typegen (fumadocs-mdx + next typegen) first
```

`postinstall` runs `fumadocs-mdx`. A missing content type or a "cannot find
`.source`" error after a fresh clone almost always means that did not run —
re-run `bun install` or `bunx fumadocs-mdx` rather than hand-writing the type.

## Renders `code-tree-graph`

The dependency graphs, file trees and type tables on this site come from
`packages/code-tree-graph`. A change to that package's props breaks the docs
build, not its own tests.
