The element to be determined whether it is included in array
.
The array to be determined whether it includes element
.
Whether whether array
includes element
.
Returns whether set
includes element
.
Logically this is the same as set.has(element)
, but is typed differently to accommodate the
scenario in which set
contains literal-type elements. See is-one-of for details.
The element to be determined whether it is included in set
.
The set to be determined whether it includes element
.
Whether whether set
includes element
.
A catch-all overload of the other two overloads. Check out the other two overloads for details.
This overload addresses the edge case in which collection
may be either a Array or
Set, and is expected to be used rarely.
Returns whether
array
includeselement
.Logically this is the same as
array.includes(element)
, but is typed differently to accommondate the scenario in whicharray
contains literal-type elements. See is-one-of for details.