Documentation Authoring Style
Prefer Docusaurus for comprehensive docs
- Primary docs live in
packages/docs/docs/. - Use Markdown for simple pages; use MDX when you need interactive previews.
Follow the house structure
For new pages, aim for:
- Overview (what, when to use)
- Mental model (how to think about it)
- Quick start (minimal example)
- API reference (method-by-method, with return types and gotchas)
- Examples (one minimal, one realistic)
- Notes (edge cases, back-compat, performance)
Write examples like the repo
- Use the fluent builder style (
viz().view(...).node(...).edge(...).done()). - Prefer deterministic ids (e.g.
a->b) and explain conventions. - Keep snippets copy/paste-able and consistent with
README.md.
Use interactive MDX patterns when useful
- Use
CodePreview+VizMount(andVizPlaybackControlsfor timelines) like existing docs. - Keep demo builders/scenes declared near the top of the MDX file.
Link to types
- When referencing types/specs, link to
types.mdxanchors (e.g.AnimationSpec,TweenSpec). - Update
types.mdxwhen new public types or fields are introduced.
Source: ChipiKaf/vizcraft — distributed by TomeVault.