Horje
Remove all child nodes of a list: Code Example
Remove all child nodes of a list:
// Get the <ul> element with id="myList"
let list = document.getElementById("myList");

// As long as <ul> has a child node, remove it
while (list.hasChildNodes()) {  
  list.removeChild(list.firstChild);
}




Javascript

Related
process memory usage javascript Code Example process memory usage javascript Code Example
Pick Random Value From Array Code Example Pick Random Value From Array Code Example
react on link click scroll to top Code Example react on link click scroll to top Code Example
set a discord js v12 bot activity Code Example set a discord js v12 bot activity Code Example
db.json Code Example db.json Code Example

Type:
Code Example
Category:
Coding
Sub Category:
Code Example
Uploaded by:
Admin
Views:
7