baoyu-markdown-to-html
Skill by JimLiu
Converts Markdown files to styled HTML with WeChat-compatible themes. It is for writers and editors who prepare articles for WeChat Official Accounts.
Install baoyu-markdown-to-html
Built from the published package, never by AI.
git clone --depth 1 https://github.com/JimLiu/baoyu-skills /tmp/baoyu-skills && mkdir -p ~/.claude/skills && cp -r /tmp/baoyu-skills/skills/baoyu-markdown-to-html ~/.claude/skills/baoyu-markdown-to-htmlRun in your terminal. Claude Code loads skills from ~/.claude/skills automatically.
git clone --depth 1 https://github.com/JimLiu/baoyu-skills /tmp/baoyu-skills && mkdir -p ~/.gemini/antigravity-cli/skills && cp -r /tmp/baoyu-skills/skills/baoyu-markdown-to-html ~/.gemini/antigravity-cli/skills/baoyu-markdown-to-htmlAntigravity CLI loads skills from ~/.gemini/antigravity-cli/skills, or .agents/skills for one project.
Step-by-step: install baoyu-markdown-to-html in Antigravity CLI
Skills can run scripts on your machine. Some need an API key: check the README.
About
baoyu-markdown-to-html is an agent skill that converts a Markdown file into styled HTML with inline CSS. The output is optimized for WeChat Official Accounts. The skill offers four themes (default, grace, simple and modern), color presets, and options for font family and font size. It runs a Bun script, main.ts, that writes an HTML file next to the source file and prints a JSON result with the file paths.
It supports code highlighting, math, Mermaid diagrams rendered to PNG through headless Chrome, PlantUML, footnotes, alerts and infographics. An optional citation mode moves ordinary external links into a bottom reference list. Users can set defaults such as theme, custom CSS variables and Mermaid options in an EXTEND.md file. It suits people who publish long-form articles to WeChat and want HTML that keeps its styling.
Written from the project's SKILL.md and checked against it.
What it can do
- Theme selectionConverts Markdown using one of four themes: default, grace, simple or modern.
- Color and font optionsSets a primary color by preset or hex value, plus font family and font size.
- Code and mathAdds syntax highlighting to code blocks and supports math.
- Mermaid renderingRenders Mermaid blocks to PNG through headless Chrome, with a pre fallback if that fails.
- PlantUML diagramsHandles ```plantuml blocks in the Markdown source.
- Bottom citationsWith --cite, moves ordinary external links to numbered references under a 引用链接 section.
- Footnotes and alertsSupports [^1] footnotes and GitHub-style alerts such as > [!NOTE].
- Ruby textRenders {base|annotation} syntax as ruby text.
- Frontmatter handlingUses title, author and description from frontmatter and removes the first heading unless --keep-title is set.
- Backup of existing HTMLBacks up an existing HTML file before writing a new one.
What you need
- Bun, or npx to run bun
- Chrome, Chromium or Edge for Mermaid PNG rendering
Try asking
- Convert article.md to HTML with the modern theme and red color
- 把这篇 md 转成 html
- Convert draft.md to HTML and move external links to bottom citations
Good to know
- Mermaid PNG rendering needs Chrome, Chromium or Edge; otherwise a pre block fallback is emitted.
- Citation mode is off by default and runs only when requested.
- Mermaid render scale must be a positive number up to 4.
- An existing HTML file is backed up before it is overwritten.
Security check
ANo download-and-run commands, hidden instructions or signs of sending keys out were found.
Checked automatically: skills/baoyu-markdown-to-html/SKILL.md, skills/baoyu-markdown-to-html/scripts/main.test.ts, skills/baoyu-markdown-to-html/scripts/main.ts. This looks for known risky patterns and is not a full audit. How grades work
Inside the skill
-
SKILL.md8 KB -
scripts/bun.lock23 KB -
scripts/main.test.ts4 KB -
scripts/main.ts12 KB -
scripts/package.json170 B
Alternatives to baoyu-markdown-to-html
All alternatives →Creates importable JSON templates for the Obsidian Web Clipper. It is for users who want to clip a site, understand the available variables, or format clipped content.
Harness Creator builds, audits, and improves the instruction and state files that help AI coding agents stay reliable across sessions. It is for developers whose agents forget context, drift out of scope, or claim work is done too early.
Guides an assistant through extracting text from scanned PDFs, photographed pages, and images with OCR. Covers backends, language packs, force-OCR, and performance tuning.
Edits a named local file in place to remove AI-writing patterns, using minimal targeted changes and post-edit verification. Built for users who explicitly ask to clean, rewrite, or humanize that specific file.
Polishes, translates, or tightens existing academic manuscript prose while preserving facts, terminology, and evidence boundaries. Made for researchers revising drafts, including Chinese-to-English translation and LaTeX layout fixes.
Adds PDF form analysis and filling, table extraction, OCR, validation and batch processing to an AI assistant. Aimed at developers who run complex or high-volume PDF workflows.
Compare with obsidian-clipper-template-creator, harness-creator or xberg-extracting-with-ocr
baoyu-markdown-to-html: common questions
Does this skill need Chrome to convert Markdown?
Chrome, Chromium or Edge is needed only for Mermaid PNG rendering. If it is missing or rendering fails, the conversion still succeeds with a pre block fallback.
What happens to WeChat article links when citation mode is on?
Links to mp.weixin.qq.com stay as direct links. Other external links become numbered superscripts collected under a 引用链接 section.
Where is the HTML output saved?
The HTML file is written to the same directory as the Markdown file, using the same base name with an .html extension.
How do I install baoyu-markdown-to-html?
Run the command above to copy the skill into ~/.claude/skills/. Claude Code picks it up automatically.
Is baoyu-markdown-to-html free?
The code is published under the MIT licence. The service it connects to may have its own pricing.
Is baoyu-markdown-to-html safe to use?
It scores 94 of 100. Grades: maintenance A, licence A, quality A. Security check: grade A, no risky patterns found in the files checked. Review the code before you install. How grades work.
What are alternatives to baoyu-markdown-to-html?
Similar skills: obsidian-clipper-template-creator, harness-creator, xberg-extracting-with-ocr, file-edit-in-place.
