Fewer source tokens
208 XMarkdown tokens versus 1,219 compact HTML/SVG tokens for the original demo. Savings versus shared-component HTML: 20.3%.
Inspect the complete comparison ↗Write the idea. Describe the visual.
Let the renderer do the rest.
Charts, diagrams, equations, live controls, and complex SVG — in the Markdown you already know.
```x-chart
{
"type": "bar",
"title": "Less markup.",
"data": [ … ]
}
```Visual meaning, without coordinates.Explore 18 working examples, from plain prose to reusable vector scenes. Inspect both source representations, or edit XMarkdown and render your own.
A larger original SVG scene: three layers, seven service cards, three storage endpoints, branching connectors, reusable symbols, pattern grid, gradients, a mask, and clipping. It is rendered by the same validated XMarkdown SVG processor.
Abstraction and shared rendering reduce markup. Streaming avoids parsing the whole growing document repeatedly. Neither makes every parse faster.
208 XMarkdown tokens versus 1,219 compact HTML/SVG tokens for the original demo. Savings versus shared-component HTML: 20.3%.
Inspect the complete comparison ↗Local parse + render comparison against repeated prefixes. Cached extended render: 0.075 ms; empty cache: 0.652 ms.
Read the feature benchmark ↗XMarkdown versus 0.259 ms for bare markdown-it on the same 6,320-character prose fixture. Added capabilities have a cost.
Read the parser benchmark ↗Local synthetic workloads, named o200k_base encoding. Shared runtime code and author instructions are excluded from source counts. AI generation time, billed usage, browser layout, and reader performance have not been measured. No universal 50× parsing claim.
Original Markdown conventions, trusted processors where they help, and custom schemas for the new capabilities.
| Capability | MVP status | Implementation | Scope |
|---|---|---|---|
| Markdown, tables, strikethrough | Supported | Reused: markdown-it | Raw HTML escaped; image alt text only |
| Callouts, charts, diagrams | Supported | Custom schemas + SVG templates | Bar/line; basic graph placement |
| Mathematics | Supported | Reused: lazy KaTeX | Bounded TeX → native MathML |
| Controls and drawing | Supported | Custom interpreter + browser runtime | Known widgets; no author programs |
| Vector scenes and SVG imports | Supported subset | Custom validation; reused SAX XML parser | Paths, gradients, clips, masks, symbols |
| Incremental previews and cache | Supported | Custom stream coordinator + cache | Provisional patches; final complete parse |
| Browser parser and React | Supported | Same native core; lazy adapters | Async browser API; worker planned |
| Mermaid, task lists, image policy | Planned | Future adapters | Mermaid currently stays source |
Imported SVG follows a static profile. Scripts, event handlers, external assets, CSS stylesheets, filters, animation, and foreignObject are rejected. Arbitrary applications still belong in HTML and JavaScript.
Read exact syntax and limits →This showcase uses our actual parser and renderer. Static fixtures use the Node entry. Your edits use the same core in the browser, with optional processors loaded on demand.
Clone the repository, install dependencies, and run the demo. Install the MVP with npm. Node, browser, React, and TypeScript exports share the same renderer.
Get the source ↗git clone https://github.com/muhammadhaseebiqbal-dev/XMarkdown.git
cd XMarkdown
npm ci
npm test
npm run build
npm run siteimport { createParser } from './src/index.js';
const parser = createParser();
const { html, diagnostics } = parser.parse(source);