Module: utils
Type Aliases
Primitive
Ƭ Primitive: string
| number
| bigint
| boolean
| symbol
| null
| undefined
Defined in
Functions
isHTMLElement
▸ isHTMLElement(element
): element is HTMLElement
Checks whether the element
passed is a HTMLElement.
Parameters
Name | Type | Description |
---|---|---|
element | unknown | The element to check. |
Returns
element is HTMLElement
true
if element
is an instance of HTMLElement
Defined in
isPrimitive
▸ isPrimitive(primitive
): primitive is Primitive
Checks whether the primitive
passed is of a primitive type.
Parameters
Name | Type | Description |
---|---|---|
primitive | unknown | The value to check. |
Returns
primitive is Primitive
true
if primitive
is of any primitive type.
Defined in
isText
▸ isText(element
): element is Text
Checks whether the element
passed is a Text.
Parameters
Name | Type | Description |
---|---|---|
element | unknown | The element to check. |
Returns
element is Text
true
is element
is an instance of Text
Defined in
notNullish
▸ notNullish<T
>(object
): object is NonNullable<T>
Checks whether the object
passed is nullish i.e., null
or undefined
.
Type parameters
Name |
---|
T |
Parameters
Name | Type | Description |
---|---|---|
object | T | The object to check. |
Returns
object is NonNullable<T>
true
if object
is not nullish.