JSFiddle - React, Tailwind, and code Playground
HTML
<script src="https://raw.github.com/iamnoah/element.write/master/element.write.js"></script>
<script src="https://raw.github.com/iamnoah/writeCapture/writeCapture2/writeCapture2.js"></script>
<input type="button" name="reload" onclick="reload();" value="Reload"/>
<div id='test1' style="height:100px;width:800px;border:solid 1px black;">
</div>
<div id='test' style="height:100px;width:800px;border:solid 1px red;">
</div>
JavaScript
function reload(){
writeCapture(document.getElementById('test'),function(){
/* document.getElementById('test1').innerHTML = document.getElementById('test').innerHTML;
$('#test').html('');*/
alert('done');
}).
write('<scr'+'ipt src="https://raw.github.com/ulhas666/ad-ref-test/master/adref.js"> </scr'+'ipt>').
close();
}