Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Support for audio and video media types #584

@JShorthouse

Description

@JShorthouse

It would be nice if this library had an option to enable html embedding of audio and video.

As an example, pandoc already supports this using the image embed syntax.

Example file:

![](image.png)

![](video.mp4)

![](audio.wav)

Pandoc:

$ pandoc test.md --to html5
<p><img src="image.png" /></p>
<p><video src="video.mp4" controls=""><a
href="video.mp4">Video</a></video></p>
<p><audio src="audio.wav" controls=""><a
href="audio.wav">Audio</a></audio></p>

Currently, for the same input, pulldown-cmark outputs:

<p><img src="image.png" alt="" /></p>
<p><img src="video.mp4" alt="" /></p>
<p><img src="audio.wav" alt="" /></p>

For anyone else with this issue: as workaround for now, you can just put <video> tags directly in the markdown, and pulldown-cmark will leave them there in the generated html.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions