JSFiddle - React, Tailwind, and code Playground

HTML

<div id="ip"> 
   <input type="text" name="first" value="cobra" class="mark1"/>
   <input type="text" name="second" value="python" class="mark2"/>
</div>

<div id="demoDiv">

</div>

JavaScript

var a = (document.getElementById("ip").outerHTML);
a.toString()
$("#demoDiv").append($.parseHTML(a))