Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HTML to Markdown #719

Open
colinodell opened this issue Sep 20, 2021 · 1 comment
Open

HTML to Markdown #719

colinodell opened this issue Sep 20, 2021 · 1 comment
Assignees
Labels
do not close Issue which won't close due to inactivity enhancement New functionality or behavior
Milestone

Comments

@colinodell
Copy link
Member

#419 and #511 require the ability to render the AST to Markdown. If we also add the ability to parse HTML into the AST then we could replace league/html-to-markdown with this package! Using an intermediate AST would also help with some of the issues/challenges in the other library.

@colinodell colinodell added enhancement New functionality or behavior do not close Issue which won't close due to inactivity labels Sep 20, 2021
@colinodell colinodell added this to the v3.0 milestone Sep 20, 2021
@colinodell colinodell self-assigned this Sep 20, 2021
@stefanzweifel
Copy link

stefanzweifel commented Jul 29, 2023

Just came across this issue and wanted to share, that I've written an extension that can convert an AST back to Markdown back in August 2021: https://github.com/stefanzweifel/commonmark-markdown-renderer

(I use this in a CLI to add release notes to CHANGELOG files with GitHub Actions.)

As you mentioned in #419 (comment), such a renderer has quite a lot of edge cases. My package isn't perfect by any means. (Currently struggling to support multi-line list items for example)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
do not close Issue which won't close due to inactivity enhancement New functionality or behavior
Projects
None yet
Development

No branches or pull requests

2 participants