JSFiddle - React, Tailwind, and code Playground
by John Doe
HTML
<button id="remove">удалить</button>
<button id="reset">востановить</button>
<div id="content">
Some text
</div>
JavaScript
var content;
$('#remove').click(function(){
content = $('#content').detach();
});
$('#reset').click(function(){
$('body').append(content);
});