Skip to content

Let a coding agent read these docs

Point a coding agent at the docs — the llms.txt index and its files, one per topic, or @aparte/docs-mcp, an MCP server that searches and reads them.

On this page

/llms.txt is the library in a paragraph and a file per topic, each named in a sentence. Hand the index to a model that can fetch, or only the file of the topic at hand:

TopicHolds
Getting started, frameworks and guidesInstall, first render in vanilla or a framework, and every guide (theming, tools, persistence, branching, localisation, accessibility, troubleshooting).
Tools, approval and asking the userRegistering tools, the tool-call row, human-in-the-loop approval, typed questions to the user (elicitation), and the ask-user plugin.
Run the agent loop on your servercreateAparteAgentHandler on the server and createAgentStreamRunner in the page: tools run next to your server, approvals cross the network and survive a reload, browser tools still run in the page.
Bring your own loop (display-only)Driving the transcript from a loop you own: appendMessage, segments, token streams, finishing a turn, the wrappers' imperative API, the backend transport.
Theming and the UI kitCSS variables, dark mode, the customization hooks, and the kit of plain classes (buttons, fields, alerts, tags, menus, tabs) with their HTML.
Providers and transportsOpenAI-compatible endpoints, the AI SDK bridge, a model in the browser, the scripted scenario provider, local models, writing your own provider.
Reference: components, segments, events, configEvery custom element with its attributes, events and CSS properties; every segment shape; the event map; the config object; the icons.

/llms-small.txt is every page but the element pages and the generated references — classes, CSS variables, events, icons — shortened, for a small context window; /llms-full.txt is everything.

bash
claude mcp add aparte-docs -- npx -y @aparte/docs-mcp
json
{ "mcpServers": { "aparte-docs": { "command": "npx", "args": ["-y", "@aparte/docs-mcp"] } } }

A client that speaks the Model Context Protocol — Claude Code, Claude Desktop, Cursor and the others — gets the same text through four tools:

ToolAsk it for
list_setsthe topics, a sentence each: start here
search_docsthe pages that match plain words — "approve a tool call", "systemPrompt false" — with a snippet
get_pageone page’s Markdown, by its title or a distinctive part of it
get_seta whole topic at once

The server reads https://apartejs.dev, so it serves the docs online, and it needs the network. APARTE_DOCS_URL points it at another docs build, served over http — for an offline or a staging setup: claude mcp add aparte-docs -e APARTE_DOCS_URL=http://localhost:4321 -- npx -y @aparte/docs-mcp, or "env": { "APARTE_DOCS_URL": "http://localhost:4321" } in the JSON entry. To embed it in a host of yours, createDocsMcpServer({ baseUrl }) returns the McpServer, and DocsSource, parseIndex, splitPages and searchPages give the text without the protocol.