HTML DOM Document importNode()
HTML DOM Document importNode() Property
The importNode() method is used for importing a node from another document. By settings its 2nd parameter to true, we can also import its child. The imported node is just a copy and it does not remove the original document.
Syntax:-
Its syntax is:- document.importNode(node, deep)
Return:-
Its return is:- imported node
Further Explanation:-
Parameter | Description |
node | Required. A node from another document. |
deep |
Required. If set to false then the node itself is imported. If set to true then child nodes also included. |