gomarkdown / markdown

markdown parser and HTML renderer for Go
Other
1.36k stars 171 forks source link

md.Renderer implementation status #285

Open wader opened 1 year ago

wader commented 1 year ago

Hello! I'm in the need for a markdown renderer so i've thought about giving a go at finishing or improve md.Renderer but would like to ask if it would be welcome and if there has been any previous attempt at doing it that could be useful?

kjk commented 1 year ago

Sure, that would be great.

Other than the code already there, I don't know of any other code that would be very relevant.

miekg commented 1 year ago

this might help too: https://github.com/mmarkdown/mmark/commit/6e26b214bd1650984cf8502e6802237da7383291 it's the commit where I deleted to markdown renderer for mmark (which has more complex constructs)

wader commented 1 year ago

@miekg Thanks that looks very useful 👍

gen2thomas commented 7 months ago

Hi @wader , is there any progress for the md.Renderer? It seems some ast types are not supported yet.

panic: node *ast.HorizontalRule NYI

wader commented 7 months ago

@gen2thomas Not much progress. If i remember correctly i implement a few more node type but then got derailed with something else. My use case for this would be to batch transform/reformat md files.

gen2thomas commented 7 months ago

@wader thanks for your fast reply. My use case is update parts of one md document by parts of other md documents. Do you have a fork to get some ideas? Meanwhile I will test this tool, based on goldmark: https://github.com/teekennedy/goldmark-markdown

wader commented 7 months ago

Can try see if i can find the work in progress branch, but i don't think i got very far