Markdown’s Simplicity and Complexity: Syntax, Extensions and Security

Theo Browne examines a critique of Markdown, from equivalent syntax to inline HTML and the complexity of document processing.

TBTheo Browne연사 · T3
채널
Theo - t3․gg
게시일
2026년 4월 27일
영상
22:06
읽기
6분
슬라이드
4
원문
영어
YouTube에서 열기
스크롤하면 영상이 오른쪽 아래로 작아져 계속 재생됩니다. 자막은 읽기 언어를 따릅니다.
읽기 언어2개 언어로 읽을 수 있음
이 글은 아직 한국어 번역이 없어 영어 원문으로 표시합니다.
요약

30초 요약

Theo Browne reflects on his long appreciation for Markdown while examining Brock’s critique of its syntax and extensions. He discusses parser vulnerabilities, inline HTML, reference resolution and proposed alternatives, highlighting the tradeoff between convenient source text and the complexity of the full processing pipeline.

  1. 1Readable sourceMarkdown makes simple documents easy to write and share as text.
  2. 2Many equivalent formsDifferent heading and emphasis spellings increase the cases implementations must handle.
  3. 3Parser securityA markdown-it advisory concerns specific affected versions, not every Markdown parser.
  4. 4Document-wide referencesA later definition can determine whether earlier text becomes a reference link.
  5. 5A proposed alternativeThe author suggests a defined markup format with explicit extensions and a build system.

핵심 정리

  1. Markdown is convenient for simple text, but equivalent forms and extensions complicate rendering.
  2. Inline HTML and executable extensions require explicit trust and security decisions.
  3. CommonMark reference links can depend on definitions elsewhere; footnotes are an extension.
  4. A vulnerability in a specific parser version should not be generalized to every implementation.
  5. Choose document tooling according to required features, processing and security boundaries.
전문

챕터별로 다듬은 전문 읽기

원본 자막만 보기
01

Why question Markdown?

Theo explains why he adopted Markdown and why expanding its role raises questions.

I have advocated for Markdown for years. I once kept my résumé on GitHub as Markdown and even avoided some applications that would not accept it. Its appeal was a simple, readable source that could become a nicely formatted document without elaborate tooling.

I am grateful to John Gruber and Aaron Swartz for creating Markdown. After struggling with LaTeX in college, I found a format that clicked and became my default for writing. That history is why an article asking why we still use Markdown caught my attention.

Markdown’s scope has expanded beyond simple documents. We embed other formats, add extensions and increasingly use Markdown to communicate with language models and agents. I want to question where the original format works well and where our newer demands create friction.

02

Simple to write, complex to parse

The article contrasts approachable syntax with multiple equivalent forms and parser edge cases.

The article I am reading is “Why the heck are we still using Markdown?” by Brock: https://bgslabs.org/blog/why-are-we-using-markdown/. The author focuses primarily on CommonMark and argues that a format intended to be simple has accumulated difficult syntax and expectations. I agree with much of the frustration, even though I still use it every day.

The good part is real: basic Markdown is approachable, readable in plain text and convenient for headings, emphasis and links. CommonMark gives implementations a detailed shared specification. A casual author can get useful output quickly without learning the full set of parsing rules.

Different syntax, similar output
슬라이드 1 / 4Different syntax, similar outputTwo Markdown forms produce the same displayed structure in the article’s example.

The trouble begins when multiple spellings produce the same result. The article shows one heading written with a hash and another using an underline; it also switches between asterisks and underscores for emphasis. These choices can be convenient for writers but create more cases for tools to handle.

Nested emphasis can become hard to read even before implementing a parser. In T3 Chat we have encountered many odd rendering cases, especially with generated content. A simple-looking format can therefore impose substantial complexity on the software that must accept all of its valid forms.

The article points to a regular-expression denial-of-service vulnerability in markdown-it. This is a bug in particular affected versions and code paths, not evidence that every Markdown parser is vulnerable. The advisory identifies versions 13.0.0 through before 14.1.1 and a fix in 14.1.1: https://github.com/advisories/GHSA-38c4-r59v-3vqw.

03

Inline HTML and extensions

Mixing formats adds power and complexity. Security depends on the implementation and trust boundaries.

The author compares inline HTML in Markdown to adding a powerful escape hatch. It lets a writer use elements and attributes the basic syntax cannot express, but now the rendering pipeline must decide how to handle two different syntaxes and their interactions. That flexibility has a cost.

Inline HTML example
슬라이드 2 / 4Inline HTML exampleThe example mixes Markdown text with HTML elements and attributes.

I have felt this problem personally. A friend tried to use the same bytes as both a GitHub profile Markdown file and an HTML home page; making the two rendering environments agree was painful. The fact that some HTML can appear in Markdown does not mean every renderer treats the combined document identically.

Writers often want more than headings and paragraphs: embedded media, diagrams, mathematics, footnotes, citations, styling or interactive components. Each added capability introduces choices about syntax, dependencies and trust. A tool intended as a lightweight text format starts to resemble a document-processing system.

I looked at my own blog and quickly found an iframe and an HTML image inside a Markdown link. The point is not that those particular snippets are inherently unsafe; it is that real publishing requirements push us beyond the simplest Markdown examples and into mixed-format workflows.

HTML embedded in a blog post
슬라이드 3 / 4HTML embedded in a blog postTheo shows an image element inside a Markdown link in his own source.

Allowing raw HTML, plugins or executable extensions changes the security model. When content is untrusted, the application needs appropriate sanitization and boundaries; a parser alone is not a complete security policy. Different implementations and configurations carry different risks.

04

Legacy syntax and references

Theo considers multiple syntax forms and document-wide reference resolution. CommonMark footnotes are extensions, not core syntax.

Markdown borrowed conventions from plain-text email and online discussions. That history left several ways to express similar structures: heading styles, list markers, horizontal rules and emphasis delimiters. Familiarity makes them easy to use, but overlaps and variations make edge cases harder to reason about.

Numbered lists are another example: authors can use repeated markers and rely on the renderer to produce the displayed sequence. That is convenient when reordering items, but the text a person sees in the file and the rendered output do not always match one-to-one.

The article shows a reference whose interpretation depends on whether a matching definition appears elsewhere in the document. CommonMark supports reference links; footnotes are an extension rather than a core CommonMark feature. A renderer may need a document-wide reference table or multiple passes to resolve such links.

Reference definition example
슬라이드 4 / 4Reference definition exampleA definition elsewhere in the document changes how the reference is rendered.

The author describes that dependency using formal-language terminology and argues that Markdown is more complicated than a simple local substitution. The practical observation is sound: later definitions can affect earlier references. The formal classification is the author’s argument, not something established merely by the example shown.

05

Alternatives and tradeoffs

A proposed build system and constrained extensions could clarify a format’s purpose. Each choice still carries complexity and security decisions.

Add footnotes, custom callouts, mathematics and styles, and the processing pipeline grows further. A knowledge-management system may need plugins and typesetting libraries as well as a way to scope styles. The format choice should account for the whole pipeline, not just the characters an author types.

I like one different use of Markdown syntax in Notion: typing a hash and a space can turn a block into a heading. There, familiar syntax acts like a shortcut in an editor. That is a distinct use from storing and rendering an entire document as Markdown, and the export can have its own limitations.

The author considers plain text, reStructuredText and MDX, but finds tradeoffs in each. The proposed alternative is a clearly specified markup format with a build system, explicit shortcodes and controlled hooks instead of unrestricted inline HTML. That is a design proposal, not an already demonstrated universal replacement.

A build system and hooks can make extension points explicit, but they also introduce their own complexity and security decisions. The key question is which features a document actually needs and which code is trusted to run during processing. A cleaner grammar alone does not make arbitrary extensions safe.

The article also ventures into formal language theory and definitions of programming languages. Those distinctions depend on the precise language and computational model being discussed; an entertaining argument about Markdown should not be taken as proof that Markdown itself is Turing-complete.

There have been complaints about Markdown’s ambiguities and implementation bugs for a long time, including calls for a clearer standard. CommonMark is one response to that history. Standardizing behavior can improve consistency while still leaving open the question of whether the chosen behavior is pleasant or appropriate for a particular application.

The article made me appreciate how much complexity I have accepted in a format I use every day. I am not proposing that everyone rewrite their documents immediately. I want us to recognize the tradeoff: Markdown is pleasant for simple text, while extensions, mixed HTML and rendering requirements can make the surrounding system much harder.

I am tempted to invent a new markup language, but that temptation is not a solution by itself. First decide what you need to express, how documents are processed and what security boundaries matter. Then choose or design tooling for those requirements.

같은 채널의 다른 글

슬라이드 5장38:47EN
Theo - t3․gg· 2026년 10월 28일Theo’s Long-Running Agent Experiments: Verification, Compute and CostTheo Browne · Ping LabsA skateboard game and two compiler projects show how repeated checks and flexible compute can sustain agent work—and how expensive those loops can become.코딩 에이전트에이전트 엔지니어링AI cost & performance+2
슬라이드 5장36:07EN
Theo - t3․gg· 2026년 10월 27일Theo on Token Costs, Coding Agents, and the Price of AI CapabilityTheo Browne · Ping LabsA viral estimate of Lauren's AI spending prompts a closer look at cache pricing, benchmarks, and the changing work of coding agents.AI cost & performance코딩 에이전트Inference+1
슬라이드 5장30:37EN
Theo - t3․gg· 2026년 10월 26일Theo’s Three Skills for Reviewing and Shipping with Coding AgentsTheo Browne · Ping LabsHow sol-loop, full-send and full-stop encode review, verification and different levels of merge authority.Agent skills코딩 에이전트Code review & verification+2
슬라이드 2장0:43EN
Theo - t3․gg· 2026년 10월 23일Theo Distinguishes Security Vulnerabilities from Active AttacksTheo Browne · Ping LabsA short explanation of why disclosed software flaws and reported attacks are different kinds of security news.CybersecuritySoftware engineering
슬라이드 6장29:22EN
Theo - t3․gg· 2026년 10월 22일Theo on Security Vulnerabilities, Stolen API Keys and AITheo Browne · Ping LabsA look at the gap between vulnerability disclosure and patching, and a speculative account of why stolen inference keys may be valuable.CybersecurityAI securitySoftware engineering+1
슬라이드 4장31:13EN
Theo - t3․gg· 2026년 10월 20일Theo on Why Smarter Models Help More Than DevelopersTheo Browne · Ping LabsFrom game modifications to compiler experiments, Theo revisits his assumptions about who benefits from more capable AI.코딩 에이전트Developer productivityHuman-AI Collaboration+1