Applies function to the elements of iterator and returns the first non-none result.
firstMap(fn) is the lighter version of filterMap(fn).first().
firstMap(fn)
filterMap(fn).first()
An array
A function that produces an Option.
Option
Optional
If provided, it will be used as the this value for each invocation of predicate. If it is not provided, undefined is used instead.
undefined
The first non-none result.
Applies function to the elements of iterator and returns the first non-none result.
firstMap(fn)
is the lighter version offilterMap(fn).first()
.