JSFiddle - React, Tailwind, and code Playground
HTML
<div id="test">
</div>
JavaScript
function addHTML(html, elementId) {
if (document.createElement) {
var holder = document.createElement('div');
holder.innerHTML = html;
var target = document.getElementById(elementId);
while (holder.hasChildNodes()) {
target.appendChild(holder.firstChild);
}
}
}
addHTML("<embed height='100' width='100' type='application/x-shockwave-flash' allowscriptaccess='always' wmode='transparent' quality='high' swliveconnect='true' name='test' id='test' src='test.swf'>", 'test');