Recent | Popular
#firstchild #remove
// Select the parent element const parent = document.getElementById('parentElementId'); // While the parent has child nodes, remove the first one while (parent.firstChild) { parent.removeChild(parent.firstChild); }
Mon Jul 29 2024 08:32:29 GMT+0000 (Coordinated Universal Time)