dom/isElement

Checks whether a value is a DOM element.

Source:

Methods

(static) isElement(value) → {boolean}

Source:
Example
import { isElement } from '@untemps/utils/dom/isElement'

isElement(document.createElement('div')) // true
isElement(42) // false
Parameters:
Name Type Description
value *

The value to check.

Returns:

true whether the value is a DOM element.

Type
boolean