mirror of
https://github.com/Hopiu/python-markdown-oembed.git
synced 2026-03-16 22:10:24 +00:00
Markdown extension to allow media embedding using the oEmbed standard.
The reasoning is that the translation of Markdown into HTML should be as concise as possible. The semantics of the figure element seem to fit the embedded nature of OEmbed content moreso than the div element which is quite generic. |
||
|---|---|---|
| mdx_oembed | ||
| .gitignore | ||
| LICENSE | ||
| MANIFEST.in | ||
| README.markdown | ||
| setup.py | ||
| tests.py | ||
Python Markdown oEmbed
Markdown extension to allow media embedding using the oEmbed standard.
Installation
pip install python-markdown-oembed
Usage
>>> import markdown
>>> md = markdown.Markdown(extensions=['oembed'])
>>> md.convert('')
u'<iframe width="459" height="344" src="http://www.youtube.com/embed/zqnh_YJBvOI?fs=1&feature=oembed" frameborder="0" allowfullscreen></iframe>'
Links
License
A Public Domain work. Do as you wish.