TanStack Markdown implements a documented subset aimed at repository-authored blogs, guides, API documentation, changelogs, and release notes.
| Syntax | Support | Notes |
|---|---|---|
| ATX headings | Yes | Levels 1-6 with stable duplicate-safe IDs |
| Paragraphs | Yes | Soft line breaks remain text line breaks |
| Fenced code blocks | Yes | Backtick and tilde fences, language and docs metadata |
| Blockquotes | Yes | Nested parsing with a bounded depth |
| Unordered lists | Yes | Tight, loose, nested, and task items |
| Ordered lists | Yes | . and ) markers, custom starts, tight and loose items |
| Tables | Yes | Header delimiter and left/center/right alignment |
| Thematic breaks | Yes | Hyphen, asterisk, and underscore forms |
| Frontmatter extraction | Yes | Leading --- block, enabled by default |
| Footnotes | Yes | Definition order follows first reference |
| Raw HTML | Opt-in | Parsed and emitted only with allowHtml: true |
| Setext headings | No | Use # headings |
| Indented code blocks | No | Use fenced code blocks |
| Syntax | Support | Notes |
|---|---|---|
| Emphasis and strong | Yes | Natural prose patterns; not every pathological delimiter case |
| Strikethrough | Yes | GFM ~~text~~ and legacy TanStack ~text~ |
| Inline code | Yes | Backtick spans |
| Inline links and images | Yes | Unsafe URL protocols are removed |
| Reference links and images | Yes | Full and collapsed forms used by the maintained corpus |
| Hard breaks | Yes | Backslash before a newline |
| Raw inline HTML | Opt-in | Requires allowHtml: true |
| Autolink literals | No | Write an explicit link |
| Entity decoding | Partial | HTML is escaped; full CommonMark entity behavior is not a goal |
Code fences understand metadata used by technical documentation:
```tsx file="app.tsx" framework="react" {2,4-6}
export function App() {
return <main>Hello</main>
}
```The AST records lang, meta, title, file, framework, and highlightLines. Rendering the metadata does not add a syntax highlighter.
The docs extension entry points add:
See the Docs Preset guide.
The following are not project goals:
Unsupported input must still be deterministic, escaped by default, and bounded in runtime. New syntax requires evidence from real documentation, regression fixtures, renderer parity, and an accepted bundle cost.