Skip to content

Markdown: inline statements in page headings are escaped and render as text #10466

@enen92

Description

@enen92

Describe the bug
When the HTML code is generated from a markdown source any inline code blocks that are part of the title/heading get escaped. Consider the following example:

# Code Guidelines

## 2. Language standard

bla bla

### 2.4. `const` and other modifiers

bla bla

### 12.5. `for` loops
bla bla

### 12.8. `goto`

bla bla

### 12.9. Macros

bla bla

### 12.10. `constexpr`

bla bla

### 12.11. `std::string` vs `std::string_view`

bla bla

This renders as:

image

It contains two issues:

  • Use of <tt> tag which seems to be deprecated (see https://www.w3schools.com/tags/tag_tt.asp), it should probably use <code>
  • Text is actually escaped so the browser doesn't render it correctly (from view-source:)
image

Expected behavior

image

Screenshots
Se above

To Reproduce
See example:

tt_issue.zip

Version
Master

Stack trace
None

Additional context
Occurs regardless of it being an include file. If processed externally (without being included) the issue also occurs.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions