JSFiddle - React, Tailwind, and code Playground
HTML
<input type="checkbox" checked="checked" id="check1" />
<button id="button" onclick="clone()">Clone</button>
JavaScript
clone = function() {
jQuery('#clone').remove();
var elem = jQuery('#check1' ).clone().attr('id','clone');
jQuery('#check1').after(elem);
}