Module

rendering.parsers.python_markdown

Python-markdown parser implementation.

Classes

PythonMarkdownParser
Parser using python-markdown library. Full-featured with all extensions. Performance Note: Use…
3

Parser using python-markdown library. Full-featured with all extensions.

Performance Note:

Uses cached Pygments lexers to avoid expensive plugin discovery
on every code block. This provides 3-10× speedup on sites with
many code blocks.
Inherits from BaseMarkdownParser

Methods 2

parse
Parse Markdown content into HTML.
2 str
def parse(self, content: str, metadata: dict[str, Any]) -> str

Parse Markdown content into HTML.

Parameters 2
content str
metadata dict[str, Any]
Returns

str

parse_with_toc
Parse Markdown content and extract table of contents.
2 tuple[str, str]
def parse_with_toc(self, content: str, metadata: dict[str, Any]) -> tuple[str, str]

Parse Markdown content and extract table of contents.

Parameters 2
content str
metadata dict[str, Any]
Returns

tuple[str, str]

Internal Methods 1
__init__
Initialize the python-markdown parser with extensions.
0 None
def __init__(self) -> None

Initialize the python-markdown parser with extensions.