Skip to content

"Flattening" markdown with embedded HTML into pure markdown? #410

@lukehutch

Description

@lukehutch

I need to be able to process markdown and replace embedded HTML content with the nearest markdown equivalent, e.g. replacing an HTML img element with a markdown embedded image link. The Copy Down library is great for HTML-to-MD conversion. However, I don't know how to use the Visitor pattern in CommonMark to replace an inline or block HTML element with markdown text. Can you please provide some guidance on how to do this?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions