node.cloneNode() method creates a copy of a node (including attributes and their values) and returns the clone.
Note: It does not copy event listeners added using addEventListener() or those assigned to element properties.
|deep||Optional||If true, the children of the node should also be cloned.|
If false, to clone only the specified node.
|Object||Returns a duplicate of the node on which this method was called.|
Clone Node Only (not text)
Please do google search for:
Join Our Channel
This channel is primarily useful for Full Stack Web Developer.