Documentation site for desktop: the computer image, the daemon API, the TypeScript SDK, and setup guides.
Built with Next.js (App Router) + Tailwind + shadcn/ui, in strict black & white. Run with bun.
bun install
bun run dev # http://localhost:3000Production:
bun run build
bun run start-
Content is plain Markdown. Every docs page lives in
content/docs/*.mdwith a tiny frontmatter block:--- title: The page title description: One-line summary shown under the title. ---
The filename becomes the URL:
content/docs/sdk.md→/docs/sdk. GFM (tables, task lists), syntax-highlighted fenced code blocks, and#anchorheadings all work. -
Navigation is one config. The sidebar, breadcrumbs, and prev/next pager are driven by
lib/nav.ts. Add a page: drop the.mdfile incontent/docs/and add an entry tonav. -
Rendering.
app/docs/[slug]/page.tsxreads the file withgray-matter, extracts the h2/h3 outline for the "On this page" rail, and renders the body withreact-markdown+remark-gfm+rehype-slug+rehype-highlight(grayscale theme defined inapp/globals.css). All routes are statically prerendered at build time.
app/
├── page.tsx # landing page
├── docs/
│ ├── layout.tsx # site header for all docs pages
│ ├── page.tsx # /docs → redirect to introduction
│ └── [slug]/page.tsx # renders a markdown file
components/ # markdown renderer, sidebar, TOC, code blocks…
lib/
├── nav.ts # sidebar config (pure data)
└── docs.ts # fs + frontmatter + heading outline helpers
content/docs/*.md # the actual documentation