mistlefoot

Extended markdown features for mistletoe, including subscript, superscript, highlighting, emojis, footnotes, task lists, and more.

Apache-2.0 13 个版本 Python >=3.10
安装
pip install mistlefoot
poetry add mistlefoot
pipenv install mistlefoot
conda install mistlefoot
描述

mistlefoot

Installation

pip install mistlefoot

Features

  • Subscript & Superscript: H~2~O and E=mc^2^
  • Highlighting: ==marked text==
  • Strikethrough: ~~deleted text~~
  • Emojis: :smile: :rocket: :heart: (50+ supported)
  • Auto-linking: URLs automatically become clickable links
  • Footnotes: Reference[^1] with definitions
  • Task lists: GitHub-style checkboxes
  • Heading attributes: Add IDs, classes, and custom attributes to headings

Usage

from IPython.display import HTML,Markdown,display
from mistletoe import markdown
markdown('**aa**', ExtendedHtmlRenderer)
'<p><strong>aa</strong></p>\n'
def render_md(md): return HTML(markdown(md, ExtendedHtmlRenderer))
def  print_md(md):       print(markdown(md, ExtendedHtmlRenderer))
markdown_text = """
#### My Document {#intro .important}

This is **H~2~O** and ==highlighted text==.

Check out https://fast.ai :rocket:

- [x] Done
- [ ] Todo
"""

render_md(markdown_text)

My Document

This is H2O and highlighted text.

Check out https://fast.ai 🚀

  • Done
  • Todo

Examples

Scientific notation:

render_md("H~2~O and E=mc^2^")

H2O and E=mc2

Emojis:

render_md("Great work! :tada: :100:")

Great work! 🎉 💯

Footnotes:

render_md("""Here's a claim[^1].

[^1]: This is the supporting reference.""")

Here's a claim[1].

1 This is the supporting reference.

Heading attributes:

print_md('#### Section {#my-id .important data-level=\"1\"}')
<h4 id="my-id" class="important" data-level="1">Section</h4>

Contributing

By Jeremy Howard. Copyright ©️ fast.ai 2026 onwards. Contributions welcome.

版本列表
0.0.13 2026-06-22
0.0.12 2026-05-21
0.0.11 2026-05-20
0.0.10 2026-05-17
0.0.9 2026-05-17
0.0.8 2026-03-26
0.0.7 2026-03-25
0.0.6 2026-03-25
0.0.5 2026-03-13
0.0.4 2026-02-14
0.0.3 2026-02-06
0.0.2 2026-01-20
0.0.1 2026-01-19