MiaoYan Blog
Notes on writing in plain Markdown and keeping notes as local files, by Tw93.
Writing in Markdown
Syntax, math, diagrams and slides in plain Markdown files.

Choosing a Markdown editor for Mac
What to check in a Mac Markdown editor: plain files, WYSIWYG or split preview, math, sync and speed, with Typora, Obsidian, iA Writer, Bear, Zettlr, VS Code and MiaoYan compared.
Markdown cheat sheet: CommonMark, GFM and extensions
The Markdown syntax you actually use, with examples, what CommonMark and GFM each define, and what MiaoYan renders on top.
LaTeX math in Markdown: syntax, KaTeX and pitfalls
Write inline and block math in Markdown, use common LaTeX constructs, avoid dollar and underscore pitfalls, and see how MiaoYan renders KaTeX.
Mermaid in Markdown: flowchart, sequence, Gantt and timeline examples
Copy-ready Mermaid examples for flowcharts, sequence diagrams, Gantt charts and timelines in Markdown, plus PlantUML and Markmap, and which ones MiaoYan renders offline.
Markdown to slides: --- separators and MiaoYan PPT mode
Turn a Markdown note into a slide deck with --- separators, configure reveal.js options, and compare Marp, reveal.js and Slidev.
Markdown to PDF on Mac
Print a MiaoYan note to a fixed A4 PDF, and switch to Pandoc, Typora, VS Code, or the Mac print dialog for paper size and margins.
Typora alternative for Mac: split preview with MiaoYan
Why people leave Typora, WYSIWYG versus split preview, what carries over (files, math, images) and where each app is stronger.
Chinese-English spacing in Markdown notes
Why Chinese writers add a space around Latin text and digits, the exceptions, and how MiaoYan's Clean Typography command applies it without touching code.
CommonMark vs GFM: which Markdown flavor to write
What CommonMark and GitHub Flavored Markdown each define, what apps add on top, which layer MiaoYan renders, and a test file to check any editor.
Markdown code blocks: fences, language tags and nesting
Write fenced and inline code in Markdown, nest a fence inside a fence, tag languages and diff blocks, and see what MiaoYan's preview highlights.
Markdown collapsible sections with details and summary
Write a collapsible section in Markdown with details and summary, keep Markdown working inside it, and see how MiaoYan previews and exports it.
Markdown escape characters: backslash, entities and code spans
Which characters a Markdown backslash escapes, when you need it, entities and code spans as alternatives, and the dollar-sign trap in MiaoYan.
Markdown footnotes: syntax, support and fallbacks
Write [^1] footnotes and definitions, see where GitHub, Pandoc and MiaoYan render them, and fix footnotes that show as plain text.
Markdown front matter: YAML, TOML and MiaoYan
Write YAML or TOML front matter for Hugo, Jekyll and Astro, see how GitHub shows it, and what MiaoYan hides in preview and export.
Markdown images: syntax, size and broken paths
Insert images, set width with HTML, keep paths from breaking, and see how MiaoYan stores, previews and exports images.
Markdown line breaks: soft, hard and MiaoYan's setting
Why a single newline vanishes in Markdown, how backslash, two spaces and <br> differ, and what MiaoYan's Line Break setting changes in preview and export.
Markdown links and anchors: inline, reference, headings
Inline, reference and autolinks, spaces in URLs, heading anchors on GitHub, and how MiaoYan's preview handles fragments and relative links.
Markdown tables: alignment, pipes and line breaks
Write a Markdown table, align columns, escape pipes, break lines in cells, handle wide tables in MiaoYan, and fall back to HTML for merged cells.
Markdown checkboxes: task lists with - [ ] and - [x]
Make checkboxes in Markdown with - [ ] and - [x], nest them, see where they render and can be clicked, and find open tasks with ripgrep.
Markmap mind maps from a Markdown outline
Turn headings and lists into a mind map with a markmap fence, what MiaoYan renders offline, which options apply, and how it differs from Mermaid.
PlantUML in Markdown: fences, server rendering and privacy
Write sequence, class and activity diagrams in a plantuml fence, how MiaoYan renders them with plantuml.com, the privacy cost, and local or Mermaid options.
What is Markdown? A plain-text way to format
What Markdown is, where it came from, the ten marks that cover most writing, how it becomes HTML, what it cannot do, and a first note in MiaoYan.
Markdown horizontal line: ---, *** and ___
Three ways to write a horizontal rule, the setext heading trap under a text line, raw HTML, and what --- also does in MiaoYan.
Markdown comments: HTML comments and [//]: # (note)
Write comments in Markdown with <!-- --> or [//]: #, see where they stay hidden or leak, and how MiaoYan handles them in preview and export.
Bold, italic and strikethrough in Markdown, and why they break
Write **bold**, *italic* and ~~strikethrough~~ in Markdown, see why emphasis fails next to punctuation or Chinese text, and where GitHub's strikethrough differs from CommonMark.
Markdown underline, color and center text with HTML
Markdown has no underline, color, centering or super/subscript syntax. Use HTML, and see what GitHub strips and what MiaoYan's preview renders.
Markdown blockquotes and nested lists: indent rules
Write blockquotes, lazy lines, nested quotes and [!NOTE] callouts, learn why nested lists need 2, 3 or 4 spaces, and why 4 spaces can become code.
Markdown to HTML: Pandoc, markdown-it and MiaoYan export
Convert Markdown to HTML with Pandoc, cmark-gfm or markdown-it, fragment vs full page, raw HTML safety, and what MiaoYan's HTML export includes.
Markdown to Word: Pandoc, reference.docx and MiaoYan exports
Convert Markdown to a .docx with Pandoc, set fonts including Chinese through a reference document, and what MiaoYan exports instead.
Managing notes
Keep notes as local files, link them, sync them and find them again.

Local-first Markdown notes: keep them as plain files
Why plain Markdown files in your own folder beat a locked-in notes app, what it costs, and how MiaoYan reads the folder you choose.
Sync Markdown notes across devices without a sync service
Use iCloud Drive, Nutstore, Dropbox or git to sync a Markdown notes folder, set MiaoYan's Note Location, and avoid conflict copies.
Wikilinks and backlinks in Markdown notes
How [[wikilinks]] differ from normal Markdown links, what MiaoYan supports, how backlinks are built, and the portability trade-offs.
Markdown notes from the terminal with the miao CLI
Install the miao CLI, learn open, new, search, list and cat, script them, and use them with AI coding agents and the MiaoYan skill.
A lighter Obsidian alternative for Mac
What MiaoYan has and leaves out compared with Obsidian, how to open a vault, and which syntax carries over.
Markdown note version history: MiaoYan, Time Machine, git
How MiaoYan saves and restores note versions, where they live, their limits, and how Time Machine and git cover what it does not.
Export Apple Notes as Markdown and open the files
macOS Tahoe can export a Notes note as Markdown. Sequoia exports PDF only. Check the file, then open it in MiaoYan.
A Bear alternative for Mac: plain Markdown files
Export Bear notes to Markdown, move them into folders MiaoYan reads, and see what you lose without tags and gain with plain files.
Markdown on iPad: files, sync and editors
What an iPad Markdown setup needs, how MiaoYan opens your Mac's iCloud Drive folder, what to check when a note is missing, and other editors.
How to open a .md file on Mac
A .md file is plain text. Open it with TextEdit, Quick Look or a Markdown app, set a default app with Get Info, and avoid the rich text trap.
Zettelkasten with Markdown files: IDs, links and a weekly routine
Run a Zettelkasten in plain Markdown files: Luhmann's slip-box, atomic notes, file names, wikilinks, backlinks in MiaoYan, and when Obsidian fits better.