Skip to content

Latest commit

 

History

History
15 lines (10 loc) · 487 Bytes

README.md

File metadata and controls

15 lines (10 loc) · 487 Bytes

dom-utils

A collection of DOM-related utility functions

Methods

.toElementArray(HTMLElement|Array|NodeList|String)

Creates a native JavaScript array of HTMLElements from a NodeList, Query Selector, or a single HTMLElement

.getAncestry(HTMLElement, Integer)

Finds ancestors of a given HTMLElement, optionally limited to a specified number.

.getCommonAncestor(HTMLElement|Array|NodeList|String)

Finds the common ancestor of a set of HTMLElements.