Skip to content

Instantly share code, notes, and snippets.

@mDuo13
Last active August 13, 2025 20:24
Show Gist options
  • Select an option

  • Save mDuo13/44b624bf82b5a2230153559c2344b4cb to your computer and use it in GitHub Desktop.

Select an option

Save mDuo13/44b624bf82b5a2230153559c2344b4cb to your computer and use it in GitHub Desktop.
Header Stress Test

Header Stress Test

This page can be used to see how a Markdown parser creates IDs for different headers.

2. Edit rippled.cfg

Note that GitHub's parser drops the . characters from the ID.

rippled Server Won't Start

The presence of code font and an apostrophe may trip up some parsers.

Failed to open /etc/opt/ripple/rippled.cfg

Does the entire path get mashed into a single run-on word?

account_info

Single underscore—does it stay or does it go?

Some italic and bold text in the header.

Formatting probably doesn't contribute to the header text?

What about angle brackets, a.k.a. < and > symbols?

n>1

How do you link that "n>1" header, anyway? Turns out on GitHub it's #n1.

XRP Ledgerの概要

How does your parser handle a mix of English and Japanese characters? This is common in pages written in Japanese.

決済のためのデジタル資産

What about a title written entirely in Japanese? If your parser strips out non-ASCII characters, this might become an empty ID. Unicode-aware parsers make the text into an ID that's almost an exact match for the header.

💩

Using a single poo emoji as the header actually breaks in the GitHub parser as of 2025-08-13 (and going back several years at least). It generates an empty string as the ID, which is technically invalid HTML and also means that clicking the permalink takes you to the top of the page.

1️⃣ 🅱️🅾️🆗

Not all parsers treat all emoji the same. This header ("1 BOOK" using a mix of emoji) may end up with a non-empty string.

🇺🇸 Flag

What if you were, say, trying to differentiate text for residents of different countries by adding flags to headers? Would the IDs be different per flag?

🇩🇪 Flag

This one is the same as the previous, but using the flag of Germany instead of the USA. But how do the IDs come out?

Montréal, über, 12.89, Mère, Françoise, noël, 889

How does your parser handle accent marks?

z͇͔̜̎̌͑ä̦̲́̃lg͖͎ọ̞̲̭̣̘̗ t̝̻̬̪͉͙͍̆̇͂ͮ̑̈̌ex͓̟̐̾t

Zalgo text pushes Unicode formatting marks to an extreme.

Repeated Headers

Repeated headers should have unique IDs. But do they?

Header Stress Test

In GitHub's parser, the second instance of this header has -1 appended to its ID.

Header Stress Test

The third instance has -2 appended.

決済のためのデジタル資産

Similar things happen when the repeated header is entirely in Japanese.

決済のためのデジタル資産

... again.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment