Repository navigation
v0.2.44
Fix: track code fences line-by-line in the MDX escaper
Supersedes the regex-based escaping in v0.2.43. Griffe's Examples sections sometimes emit an unterminated ```python fence; MDX auto-closes it, but the regex required a closing fence and so escaped braces inside the trailing code (print(f"hello {name}") → print(f"hello \{name\}")).
Replaced with a line-based scanner that toggles fence state on ``` lines (mirroring CommonMark/MDX, including auto-close) and only escapes non-fenced lines. Inline code is matched single-line so multi-line backtick spans fall through to prose escaping.
Full changelog: #46