yuin / goldmark

:trophy: A markdown parser written in Go. Easy to extend, standard(CommonMark) compliant, well structured.
MIT License
3.68k stars 255 forks source link

Easy way to linearize ast to markdown? #249

Closed wdscxsj closed 2 years ago

wdscxsj commented 3 years ago

Hello, first of all thanks for this wonderful project! It really saves a lot of work. The ast interface allows flexible manipulation of the nodes, but is there an easy way to linearize the tree (or any Node, preferably) back to markdown? Manually adding markups is boring if not error prone. Maybe another built-in renderer, or something like go/printer? Thanks!

zcharym commented 3 years ago

Hoping for the same feature. I want to append a dynamic content (e.g. api table list) into markdown file, but found it can't be reversed : (