recover
recover<
E,A,B>(fallback): (data) =>TaskValidation<E,A|B>
Defined in: Core/TaskValidation.ts:155
Recovers from an Invalid state by providing a fallback TaskValidation.
The fallback receives the accumulated error list so callers can inspect which errors occurred.
The fallback can produce a different success type, widening the result to TaskValidation<E, A | B>.
Type Parameters
Section titled “Type Parameters”E
A
B
Parameters
Section titled “Parameters”fallback
Section titled “fallback”(errors) => TaskValidation<E, B>
Returns
Section titled “Returns”(
data):TaskValidation<E,A|B>
Parameters
Section titled “Parameters”TaskValidation<E, A>
Returns
Section titled “Returns”TaskValidation<E, A | B>