Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

iselement

fczbkk276.2kMIT1.1.4

Utility function that returns true if referenced object is DOM element.

readme

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

changelog

1.1.4 (2016-08-30)

Bug Fixes

1.1.3 (2016-08-29)

Bug Fixes

1.1.2 (2016-08-28)

1.1.1 (2016-08-28)

1.1.0 (2016-08-28)

Features

  • separate standalone library and module (b0e1a6f)