some module
Type aliases
Functions
Type aliases
Predicate
Ƭ Predicate: function
Defined in index.ts:6
Predicate function
Type declaration:
▸ (item
: T, index
: number): boolean
Parameters:
Name | Type | Description | |
---|---|---|---|
item |
T | next item | |
index |
number | item index in stream |
Some
Ƭ Some: function
Defined in index.ts:17
Some function (returns true when any item fits predicate)
Type declaration:
▸ (iterable
: Iterable‹T›): boolean
Parameters:
Name | Type | Description | |
---|---|---|---|
iterable |
Iterable‹T› | input stream |
Functions
some
▸ some‹T›(predicate
: Predicate‹T›): Some‹T›
Defined in index.ts:31
Function to test whether at least one element in the stream passes the test implemented in predicate
Type parameters:
▪ T
Parameters:
Name | Type | Description | |
---|---|---|---|
predicate |
Predicate‹T› | predicate function |
Returns: Some‹T›
some function
▸ some‹T›(predicate
: Predicate‹T›, iterable
: Iterable‹T›): boolean
Defined in index.ts:40
Function to test whether at least one element in the stream passes the test implemented in predicate
Type parameters:
▪ T
Parameters:
Name | Type | Description | |
---|---|---|---|
predicate |
Predicate‹T› | predicate function | |
iterable |
Iterable‹T› | input stream |
Returns: boolean
true if any element in the stream pass the test