A Bun-native CLI for MDX documentation sites with a bring-your-own-theme model. bundoc owns content discovery, MDX compile, routing, i18n, and build-time search; you own every pixel of the UI.
- 📦 Package:
packages/bundoc/— published to npm asbundoc. - 🌐 Docs: bundoc.dev — source in
packages/docs/.
For the user-facing intro, quick start, hooks reference, and config, see
packages/bundoc/README.md.
This is a Bun workspace. The root is private and only hosts the
packages/* glob; each member is a real package with its own
package.json.
bundoc/
├─ packages/
│ ├─ bundoc/ # the published library + CLI
│ └─ docs/ # bundoc.dev — also the canonical example consumer
└─ CLAUDE.md # repo conventions for AI coding agents
packages/docs depends on bundoc via "workspace:*", so edits to
packages/bundoc/src/ are picked up live by bun --filter bundoc-docs dev
— there is no install snapshot in between.
git clone https://github.com/clusterize/bundoc.git
cd bundoc
bun install
# Run the docs site (uses your local bundoc via the workspace symlink)
bun --filter bundoc-docs dev
# Tests + typecheck (both must be green before committing)
bun test
bunx tsc -p packages/bundoc --noEmitTests are co-located: foo.ts next to foo.test.ts. The dev-server
integration test lives at
packages/bundoc/src/__tests__/dev-integration.test.ts.
- Bun-only. All scripts assume Bun ≥ 1.3. No Node, no npm, no pnpm.
See CLAUDE.md for the full set of Bun-first conventions
(prefer
Bun.fileovernode:fs,Bun.serveover Express, etc.). - No
file:references between workspace members. The docs package must depend onbundocvia"workspace:*". Usingfile:..makes Bun create a content-addressed snapshot undernode_modules/.bun/bundoc@root/...that does not update when you editpackages/bundoc/src/, silently breaking the inner loop. .bundoc/cache/is the build product. bundoc pre-compiles MDX into.tsxshims becauseBun.serve's HTML-import bundler doesn't reliably honorBun.plugin()-registered.mdxloaders. The watcher recompiles single files on change and rebuilds the manifest on add/remove.
MIT — see LICENSE.