Repository navigation
Tags
Tags
docs: explain Cordis ownership and lifecycle architecture (#565) Olai's Cordis rules and the lessons from the two lifecycle/ownership PRs were spread across implementation comments and review discussions. This adds `docs/architecture/cordis.md` as a readable guide, linked from the docs index and architecture overview. The guide explains static contracts versus live dependencies, ownership and optional-provider patterns, teardown ordering, acquisition and external effects, renderer lifetimes, reconnection, and the limits of refactors and static enforcement. Examples link to the merged implementation. It distinguishes Cordis principles from Olai's Effect-backed adaptations and excludes the unimplemented routes/layout proposal. Synthesized and fact-checked with Fable (Claude Fable 5.1) and GPT 6 Astra. Fable's review prompted explicit subscription fail/resubscribe semantics, renderer-location ownership, and the pinned-engine rationale for teardown ordering. Validation: full `just ci` passed on the initial documentation head `7db9dca84` (66 ok, 0 failed). The subsequent commit `1bddf5cd0` only clarifies this guide; all 40 Markdown links/anchors and whitespace checks pass on that head. Product and test code are unchanged.
Fence the code blocks, and tell GitHub what they are. Indented blocks and bare fences render grey. Same text, now tagged: racket for outline and sexp snippets, json for payloads, console for shell sessions with a $ prompt, text for the plain output and the ASCII diagram.