@serenity-is/corelib / indexOf
Function: indexOf()
indexOf<
TItem>(array,predicate):number
Gets index of first element in an array that matches given predicate.
Type Parameters
• TItem
Parameters
array
TItem[]
Array to test.
predicate
(x) => boolean
Predicate to test elements.
Returns
number