Loading...
Loading...
Render Mermaid diagrams as SVG or ASCII art using beautiful-mermaid. Use when users need to create flowcharts, sequence diagrams, state diagrams, class diagrams, or ER diagrams. Supports both graphical SVG output and terminal-friendly ASCII/Unicode output.
npx skill4agent add iofficeai/aionui mermaidbeautiful-mermaidDependencies () auto-install on first run.beautiful-mermaid
# From file
npx tsx scripts/render.ts diagram.mmd --output diagram.svg
# From stdin
echo "graph LR; A-->B-->C" | npx tsx scripts/render.ts --stdin --output flow.svg# ASCII art for terminal display
npx tsx scripts/render.ts diagram.mmd --ascii
# Pipe directly
echo "graph TD; Start-->End" | npx tsx scripts/render.ts --stdin --ascii┌───────┐ ┌─────┐
│ Start │────▶│ End │
└───────┘ └─────┘| Type | Syntax | Best For |
|---|---|---|
| Flowchart | | Processes, decisions |
| Sequence | | API calls, interactions |
| State | | State machines |
| Class | | OOP design |
| ER | | Database schemas |
npx tsx scripts/render.ts diagram.mmd --theme github-dark --output out.svg--theme ?scripts/render.tsreferences/syntax.md