insertBefore method
Inserts the given node into this node directly before child.
If child is null
, then the given node is inserted at the end
of this node's child nodes.
Other resources
- Node.insertBefore from MDN.
Implementation
Node insertBefore(Node node, Node? child) native;