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