fx-flow v0.7.0 / pipe/strict / includes
Function: includes()
includes(value, iterable)
includes<
A
>(value
,iterable
):false
Check whether value
is in iterable
.
Type parameters
• A extends readonly []
Parameters
• value: unknown
• iterable: A
Returns
false
Example
includes('c', 'abcd'); // true
includes('e', 'abcd'); // false
includes(3, [1, 2, 3, 4]); // true
includes(5, [1, 2, 3, 4]); // false
Source
packages/core/src/pipe/strict/includes.ts:18
includes(value, iterable)
includes<
A
,B
>(value
,iterable
):value is B
Type parameters
• A
• B
Parameters
• value: A
• iterable: Iterable
<B
>
Returns
value is B
Source
packages/core/src/pipe/strict/includes.ts:20
includes(value, iterable)
includes<
A
>(value
,iterable
):boolean
Type parameters
• A
Parameters
• value: unknown
• iterable: Iterable
<A
>
Returns
boolean
Source
packages/core/src/pipe/strict/includes.ts:22
includes(value, iterable)
includes<
A
>(value
,iterable
):Promise
<boolean
>
Type parameters
• A
Parameters
• value: unknown
• iterable: AsyncIterable
<A
>
Returns
Promise
<boolean
>
Source
packages/core/src/pipe/strict/includes.ts:24
includes(value)
includes<
A
>(value
): (iterable
) =>IterableReturnValue
<A
,boolean
>
Type parameters
• A extends UniversalIterable
Parameters
• value: unknown
Returns
Function
Parameters
• iterable: A
Returns
IterableReturnValue
<A
, boolean
>