TypematterInternal Docs
DocsComponentsChangelog
English
简体中文English✓
System
Navigation
Get started
OverviewQuickstartProject structure
Core concepts
ArchitectureNavigation rulesComponents
API
Content registryBuild validation
Changelog
Changelog
Resources
Git repository
Experimental
Version 0.2.0-beta
Core concepts

Components

Experimentalv0.2.0-beta

Doc components express semantics such as notes, diffs, structured blocks, and columns. Most components can be used as MDX tags or Markdown directives.

Callout

Callouts should reflect intent:

  • Tip/Note: neutral white block for light hints or clarifications.
  • Info: blue block for stable info or consistency notes.
  • Warning: orange block for risks or hard constraints.
  • Deprecated: red block for deprecations and migration notices.
Tip

Use for hints and small reminders.

Info

Use for stable rules or consistency notes.

Warning

Use for risk or hard constraints.

Deprecated

Use to mark deprecated features or migration notices.

Alerts (GitHub syntax)

Use GitHub-style alerts in Markdown and they will map to callouts automatically.

Note

This maps to the Note callout and keeps migration syntax consistent.

Warning

Use for risks or hard constraints.

Columns

Side by side

Good for pairing concepts or steps.

Structured comparison

Helps readers quickly understand differences.

Cards

Use cards to surface key entry points, landing sections, or recommended reading. The grid defaults to four columns and collapses to two on mobile.

  • Quickstart

    Install dependencies and scaffold the docs.

  • Components

    Built-in MDX UI primitives.

  • Project structure

    Understand content and navigation layout.

  • Build validation

    CI checks for doc quality and broken links.

Cards (directive)

  • Quickstart

    Install dependencies and scaffold the docs.

  • Components

    Built-in MDX UI primitives.

  • Project structure

    Understand content and navigation layout.

  • Build validation

    CI checks for doc quality and broken links.

Link Buttons

Start Quickstart Browse components Read changelog

Badges

Beta Stable Caution

Inline syntax: Experimental.

Math Equations

Inline math uses $...$. Block math uses $$...$$ and renders with KaTeX.

Inline example: E=mc2E = mc^2E=mc2.

∫01x2 dx=13\int_0^1 x^2 \, dx = \frac{1}{3}∫01​x2dx=31​

Diff Block

Use to compare two approaches side by side. beforeLabel and afterLabel are optional when you want the top labels.

Old behaviorNew behavior
cache: "manual"

Cache strategy maintained by hand.

cache: "filesystem"

Automatically synced with the file structure.

Code Block

Use standard Markdown code fences. The renderer adds the shared code styling and copy action.

ts
export const navStrategy = "filesystem";export const contentPath = "content";

Colored Diffs

Lines starting with + or - in code blocks are rendered with diff backgrounds for upgrade guides.

diff
- cache: "manual"+ cache: "filesystem"

Code Tabs

Switch between multiple snippets inside one block. Use the code-group directive without extra JSX.

Structured Outputs
javascript
const completion = await openai.chat.completions.create({  model: "gpt-5",  messages: [{ role: "user", content: "Jane, 54 years old" }],});
Structured Outputs
javascript
const response = await openai.responses.create({  model: "gpt-5",  input: "Jane, 54 years old",});

Rich panels

For mixed content (text, images, blocks), use :::code-group with :::tab panels.

Use tabs for notes, prose, or images alongside code.

Config

toml
[docs]static = true

:::

Steps

Turn ordered lists into step-by-step flows for long procedures.

  1. Install the typematter dependencies.

  2. Update the content/ directory structure.

  3. Run npm run validate:docs before building.

File Tree

Render Markdown lists as a file tree with collapsible folders.

  • app
    • layout.tsx
    • page.tsx
  • content
    • core-concepts
      • components.mdx
  • package.jsonProject metadata

Details / Accordion

Use collapsible blocks for supporting or optional content.

Why this matters

This keeps long explanations out of the main reading flow.

Annotations

Inline annotations add contextual tooltips that still support Markdown.

This API is experimental iHeads upSee the migration guide for constraints..

Feature Matrix

Compare multiple offerings with a semantic Markdown table.

CapabilitiesChat Completions APIResponses API
Text generation
Audiocoming soon
Vision
Structured Outputs
Function calling
Web search
File search
Computer use
Code interpreter
MCP
Image generation
Reasoning summaries
On this page
CalloutAlerts (GitHub syntax)ColumnsCardsCards (directive)Link ButtonsBadgesMath EquationsDiff BlockCode BlockColored DiffsCode TabsRich panelsStepsFile TreeDetails / AccordionAnnotationsFeature Matrix