A simple component to add/remove/get child nodes.
$ component install mikanda/child
var c = child(el)
.add(child1)
.add(child2, 0);
console.log(c.getAll());
c.removeAll();
Returns a new instance of Child
.
Returns the child at index
.
Returns all child nodes.
Adds the element
as child node at the given index or appends it to the end.
Removes the given element
from the child nodes.
Removes the element at the given index
from the child nodes.
Removes all child nodes.
LGPL