flatMapOption()
flatMapOption<
A,B,E2>(f,onNone): <E1>(self) =>Either<E2|E1,B>
FlatMaps over an Option result.
Type Parametersβ
A: Aβ
The input type.
B: Bβ
The output type.
E2: E2β
The error type for None.
Parametersβ
f: (a) => objectβ
The mapping function.
onNone: (a) => E2β
Function to create error for None.
Returns: <E1>(self): Either<E2 | E1, B>β
A function that flatMaps the Either.
Sinceβ
2.0.0