Interface used for parent -> child node relationships.
https://dom.spec.whatwg.org/#interface-parentnode
To convert nodes into a node, given nodes and document, run these steps:
-
Let node be null.
-
Replace each string in nodes with a new Text node whose data is the string and node document is document.
-
If nodes contains one node, set node to that node.
-
Otherwise, set node to a new DocumentFragment whose node document is document, and then append each node in nodes, if any, to it.
-
Return node.