1.1.4 • Published 8 years ago
iselement v1.1.4
isElement
Utility function that returns true
if referenced object is DOM element.
Most similar functions just checks, if object is instance of HTMLElement
. That does not always work, because it exotic elements like SVG polygons.
How to use
import isElement from 'iselement';
isElement(my_object); // --> true/false
Documentation
isElement
Returns true
if provided input is Element.
Parameters
input
[Any]
Returns boolean