-
Notifications
You must be signed in to change notification settings - Fork 30
Description
content would like to add code blocks to titles using markdown backtick code syntax.
With a title like `<input>` HTML element the intended result would be:
In HTML contexts, to render the backticks out to HTML <code> blocks, e.g:
<h1><code>>input<</code> HTML element</h1>
In non-HTML contexts, to drop the backticks entirely, e.g.
<meta name="og:title" content="<input> HTML element" />
There may be existing logic to handle this sort of thing already, since we have mixed <code> element and text nodes in some sidebar titles.
It'll be the safest backwards-compatible change to introduce a new title_html field to render the <code> blocks in, and continue to use title (and pageTitle, and any other title-related fields we have...) for the plaintext no-backtick version.
We should also ensure there's an escaping mechanism, or we handle titles with no "closing" backtick, as there are already some titles including the character.