emailmd
以下摘录自该仓库的 README(片段) · 在 GitHub 读完整 README →
Write markdown. Ship emails. No HTMHELL.
emailmd converts markdown into responsive, email-safe HTML that works across Gmail, Outlook, Apple Mail, Yahoo, and every other client.
Install
Quick Start
> **v0.3.0 migration:** render() is now async. Update calls from render(md) to await render(md). Requires Node 20+ (MJML 5).
Charts & Data
Bar charts, progress meters, sparklines, KPI tiles, step trackers, and star ratings, each written as a plain markdown list:
They are drawn from table cells and text glyphs rather than images or SVG, so they still render when the client blocks remote images, and they redraw themselves in the plain-text part instead of collapsing to a list of numbers. See the directives reference.
CLI
emailmd also ships with a command-line interface.
Run emailmd --help for all options.
React
@emailmd/react provides a live-preview hook (useEmailmd), an iframe component, and — the full builder as a drop-in component for your own app.
Learn More
- Docs — full syntax reference, theming, frontmatter, directives, and API
- Templates — ready-made email templates you can copy and customize
- Builder — live editor to write and preview emails in your browser
MCP
emailmd ships a Model Context Protocol server, so an AI assistant can render, lint, and preview emails for you. It exposes three tools — render (markdown to email-safe HTML), lint (flag deliverability problems without rendering), and read_docs (look up emailmd syntax) — over either transport:
Published to the official MCP registry as dev.emailmd/emailmd. See the MCP docs for per-client setup.
AI
Prefer plain context over tools? emailmd is just markdown, so AI is great at writing templates. Feed the full docs to your AI tool:
Contributing
Contributions are welcome! Feel free to open an issue or submit a pull request.
> emailmd is under active development. The API may change between minor versions until we hit 1.0 — breaking changes are always called out in the changelog. See Stability & Versioning for what the semver contract covers.