code span
· Issue #1068 · Python-Markdown/markdown (original) (raw)
md_in_html: broken markdown.extensions.md_in_html
fails to escape HTML tags in monospace
text placed inside a markdown="1"
div wrapper:
import markdown markdown.markdown('
\n', extensions=["markdown.extensions.md_in_html"]) '<h1>escaped</h1>
\n'
\nescaped</h1>
\n
`escaped</h1>`
The inner <code>
element should look like this: <code><h1>escaped</h1></code>
, but instead the h1 inside the monospace
text appears as an actual <h1>
tag in the output.
Versions
- Markdown==3.3.3
- CPython 3.8.6