Skip to content

recover

recover<E, A, B>(fallback): (data) => Validation<E, A | B>

Defined in: Core/Validation.ts:202

Recovers from an Invalid state by providing a fallback Validation. 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 Validation<E, A | B>.

E

A

B

(errors) => Validation<E, B>

(data): Validation<E, A | B>

Validation<E, A>

Validation<E, A | B>