docs: virtualize crate READMEs under docs/components/

Each workspace crate's own README.md now also shows up as
docs/components/<crate>.md via nix/packages/reference-docs.nix, so it
renders on the docs site alongside the rest of docs/ without a second
hand-copied file to keep in sync. Relative links that were correct
from the crate's own position in the tree are rewritten for their new
virtual position (../docs/x.md -> ../x.md, ../<sibling-crate> ->
./<sibling-crate>.md). Landing page at docs/components/README.md, nav
bullet added to docs/README.md. No changes needed in the website
repo's docs.nix - it already walks every subdirectory generically.
This commit is contained in:
iris 2026-08-11 17:10:23 +02:00 committed by mara
commit 765bea2022
4 changed files with 90 additions and 9 deletions

13
docs/components/README.md Normal file
View file

@ -0,0 +1,13 @@
# Crate reference
One page per Rust workspace crate — its own `README.md`, unchanged, served
here for browsing alongside the rest of the docs site. **The crate's own
`README.md` is the source of truth; nothing here is hand-maintained.**
Every page is generated at build time (`nix/packages/reference-docs.nix`,
hyperhive#3051) straight from the crate's real `README.md`, so it can never
drift out of sync the way a hand-copied mirror would — edit the crate's
own README to change what shows up here.
For the one-line-per-crate index (which crate does what, at a glance)
see the main [`CLAUDE.md`](../../CLAUDE.md#repo-map) repo map instead;
this section is each crate's own, longer word on itself.