List<Element> children
read / write

List of the direct children of this element.

This collection can be used to add and remove elements from the document.

var item = new DivElement(); item.text = 'Something'; document.body.children.add(item) // Item is now displayed on the page. for (var element in document.body.children) { element.style.background = 'red'; // Turns every child of body red. }