JSFiddle - React, Tailwind, and code Playground

by cuzzea

HTML

<body>
    <table><tr><td id='cell'><input name="elem_1_Name"/></td></tr></table>
</body>

JavaScript

function asd(){
    console.log(document,document.getElementById("cell"))
    var elem = document.getElementById("cell").lastChild.cloneNode(true);
    elem.name = elem.name.replace("1","5");
    document.getElementById("cell").appendChild(elem);
}
asd()