blackfriday icon indicating copy to clipboard operation
blackfriday copied to clipboard

Markdown within html block should be parsed after blank lines

Open pebbe opened this issue 4 years ago • 3 comments

This:

<div class="myclass">
This is **bold** text
</div>

... should render as this:

<div class="myclass">
This is **bold** text
</div>

That works.


But this:

<div class="myclass">

This is **bold** text

</div>

... should render as this:

<div class="myclass">

This is <b>bold</b> text

</div>

That doesn't work.

pebbe avatar Sep 17 '19 11:09 pebbe

Any updates?

jallbrit avatar Nov 25 '19 20:11 jallbrit

This project seems to be abandoned... anyone has come across another Go package that handles HTML better (like doing the right thing for the example in this issue)?

renatoathaydes avatar Sep 09 '20 20:09 renatoathaydes

This project seems to be abandoned... anyone has come across another Go package that handles HTML better (like doing the right thing for the example in this issue)?

https://github.com/yuin/goldmark

You need to use the render option html.WithUnsafe

pebbe avatar Sep 09 '20 20:09 pebbe