JSFiddle - React, Tailwind, and code Playground
by poxel
HTML
<div class="x">1</div><div class="x">2</div><div class="x">3</div>
JavaScript
$(".x").each(function() {
$(this).removeClass("x");
$(this).prop("id","x");
});
by poxel
<div class="x">1</div><div class="x">2</div><div class="x">3</div>
$(".x").each(function() {
$(this).removeClass("x");
$(this).prop("id","x");
});