It is easy. Check it out.

Share This Post

Code in this post can be obsolete, however, principles and theory may still apply.
Suppose we want to remove all children of the node node:
while(node.firstChild) {
    node.removeChild(node.firstChild);
}
That’s all there is to it
Follow me:
Latest posts by saki (see all)

Want to collaborate on an upcoming project?