russross / blackfriday

Blackfriday: a markdown processor for Go
Other
5.42k stars 598 forks source link

Markdown within html block should be parsed after blank lines #567

Open pebbe opened 4 years ago

pebbe commented 4 years ago

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.

jallbrit commented 4 years ago

Any updates?

renatoathaydes commented 4 years ago

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)?

pebbe commented 4 years ago

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