Open questions
Decisions we have not taken yet. Each entry records what we know, so the discussion can resume without redoing the research. Resolved questions move to the relevant page of this section.
Ship the docs in the npm tarballs?
Status: not for now. Revisit later.
The idea. Add docs to each package's files, so an agent (or a person) working in a project that depends on @mrmt/* can read node_modules/@mrmt/<pkg>/docs/ without internet access.
What we found.
- Vite+ does this: its package ships
docs/and anAGENTS.md(readable innode_modules/vite-plus), which is a precedent for agent-facing docs inside a package. - The published
.d.tsfiles keep the JSDoc (comment blocks,@defaulttags, …), and agents can already browse the types. The generateddocs/api/markdown is therefore mostly a second view of what the types contain: shipping it adds weight for little. Handwritten docs (index.md, guides) carry what the types can't: intent, recipes, gotchas. - Handwritten docs are small.
docs/api/(now only for@mrmt/viteand@mrmt/vite-ui) is generated by the build and is the bulk of the folder, sofilescould includedocsand excludedocs/api. - Relative links between pages keep working from
node_modulesas long as the linked pages ship too. Links into other packages (../../vite/docs/…) would dangle there, since each package is installed on its own.
To decide.
- Ship handwritten docs only, nothing, or everything?
- Cross-package links: keep relative links and accept dangling ones in tarballs, or add a build step rewriting them to site URLs?
- Should the
marmotteCLI add a pointer tonode_modules/@mrmt/*/docsin a project'sAGENTS.md/CLAUDE.mdwhen you scaffold orsetupit? - Versioning: docs in the tarball always match the installed version, which the website can't promise.