HTML DOM
GitHub 0★
Get the parent node of an element
Returns the parent node of the
ele
element:
const
parent
=
ele
.
parentNode
;
See also
Check if an element is a descendant of another
Get the first scrollable parent of an element
Select the children of an element
Swap two nodes
Zoom an image
Get the first scrollable parent of an element
Get the position of an element relative to another