How to render markdown in html instead of react?

I understand that you use dangerouslySetInnerHTML for react;
and marked(’# Title’) in html, but in HTML, it only renders if there is only one line.

If I do more than one; e.g. marked(’ # Welcome to my React Markdown Previewer!

This is a sub-heading…

And here’s some other cool stuff:

Heres some code, <div></div> , between 2 backticks.’);

nothing renders at all. I’ve been searching for over 7 hours now trying to find the correct code for HTML to render markdown text; I want to be able render in HTML instead of react

I’m not sure that I understand exaclty what issue you are having. Do you think you could post a link to your Codepen? That might make it easier for others to see what you might need help with.