JSFiddle - React, Tailwind, and code Playground

by Kerrick

HTML

<div class="markdown">
    <h1>HTML Ipsum Presents</h1>
	       
    <p><strong>Pellentesque habitant morbi tristique</strong> senectus et netus et malesuada fames ac turpis egestas. Vestibulum tortor quam, feugiat vitae, ultricies eget, tempor sit amet, ante. Donec eu libero sit amet quam egestas semper. <em>Aenean ultricies mi vitae est.</em> Mauris placerat eleifend leo.</p>
    
    <hr />
    <p>Quisque sit amet est et sapien ullamcorper pharetra. Vestibulum erat wisi, condimentum sed, <code>commodo vitae</code>, ornare sit amet, wisi. Aenean fermentum, elit eget tincidunt condimentum, eros ipsum rutrum orci, sagittis tempus lacus enim ac dui. <a href="#">Donec non enim</a> in turpis pulvinar facilisis. Ut felis.</p>

<h2>Header Level 2</h2>
	       
<ol>
   <li>Lorem ipsum dolor sit amet, consectetuer adipiscing elit.</li>
   <li>Aliquam tincidunt mauris eu risus.</li>
</ol>

<blockquote><p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus magna. Cras in mi at felis aliquet congue. Ut a est eget ligula molestie gravida. Curabitur massa. Donec eleifend, libero at sagittis mollis, tellus est malesuada tellus, at luctus turpis elit sit amet quam. Vivamus pretium ornare est.</p></blockquote>

<h3>Header Level 3</h3>

<ul>
   <li>Lorem ipsum dolor sit amet, consectetuer adipiscing elit.</li>
   <li>Aliquam tincidunt mauris eu risus.</li>
</ul>

<pre><code>
#header h1 a { 
	display: block; 
	width: 300px; 
	height: 80px; 
}
</code></pre>
    <h1>HTML that looks like markdown</h1>

<p>When this section is styled by <code>markdown.css</code> it looks like plain-text, despite being HTML. Inspect it with firebug or click on &lt;HTML/&gt; to see the markup.</p>

<p>A <strong>strong tag</strong> and an <em>em tag</em> get styled like so.</p>
<p>How about a link to <a href="http://mrcoles.com">my site</a>?</p>

<h2>H2 header</h2>

<h3>Lists</h3>
<ul>
    <li>they look like this</li>
    <li>it’s how you’d format them in pure markdown, if you took the time...

CSS

.markdown {
    word-wrap: break-word;
}

.markdown,
.markdown h1,
.markdown h2,
.markdown h3,
.markdown h4,
.markdown h5,
.markdown h6,
.markdown pre,
.markdown code,
.markdown blockquote,
.markdown em,
.markdown strong,
.markdown code {
    font-size: 16px;
    line-height: 1.4;
    font-weight: normal;
    font-style: normal;
    font-family: consolas, monaco, courier, "courier new", fixed-width;
    color: #333333;
    max-width: 79ch;
}

.markdown h1,
.markdown h2,
.markdown h3,
.markdown h4,
.markdown h5,
.markdown h6,
.markdown pre,
.markdown code,
.markdown blockquote,
.markdown ol,
.markdown ul,
.markdown li,
.markdown p,
.markdown section,
.markdown header,
.markdown footer {
    float: none;
    margin: 0;
    padding: 0;
}

.markdown h1,
.markdown p,
.markdown ul,
.markdown ol,
.markdown pre,
.markdown blockquote {
    margin-top: 1em;
    margin-bottom: 1em;
}

.markdown h1 {
    position: relative;
    display: inline-block;
    display: table-cell;
    padding: 1em 0 2em;
    margin: 0;
    overflow: hidden;
}

.markdown h1:after {
    content: "====================================================================================================";
    position: absolute;
    bottom: 1em;
    left: 0;
}

.markdown h1 + * {
    margin-top: 0;
}

.markdown h2,
.markdown h3,
.markdown h4,
.markdown h5,
.markdown h6 {
    position: relative;
    margin-bottom: 1em;
}

.markdown h2:before,
.markdown h3:before,
.markdown h4:before,
.markdown h5:before,
.markdown h6:before {
    content: "## ";
    display: inline;
    max-width: 76ch;
}

.markdown h3:before {
    content: "### ";
    max-width: 75ch;
}

.markdown h4:before {
    content: "#### ";
    max-width: 74ch;
}

.markdown h5:before {
    content: "##### ";
    max-width: 73ch;
}

.markdown h6:before {
    content: "###### ";
    max-width: 72ch;
}

.markdown li {
    position: relative;
    display: block;
    padding-left: 4ch;
    max-width: 75ch;
}

.markdown li:after {
    position: absolute;
 ...