JSFiddle - React, Tailwind, and code Playground

by TwitchBronBron

HTML

<script src="https://unpkg.com/turndown/dist/turndown.js"></script>
<script src="https://unpkg.com/turndown-plugin-gfm/dist/turndown-plugin-gfm.js"></script>

JavaScript

const turndownService = new TurndownService({
    headingStyle: 'atx',
    codeBlockStyle: 'fenced'
});
turndownService.use(turndownPluginGfm.gfm);
const markdown = turndownService.turndown('<strong>Description: </strong>1978 Rogue 28’ w/ Carolina Room. 1 bedroom (sleeps 6) and 2 bathrooms.  Large 2nd bathroom with washer/dryer hook up.  Peaceful <strong>waterfront lot</strong>!  (Lease: <strong>December 31, 2021</strong>) ');
document.write('<pre><code>' + markdown + '</code></pre>')