( onSuccess: (a: A) => These<E1, A1>, onBoth: (a: A, e: E) => These<E2, A2>, onFail: (e: E) => These<E3, A3>, )
| 49 | } |
| 50 | |
| 51 | export function foldM<E, A, E1, A1, E2, A2, E3, A3>( |
| 52 | onSuccess: (a: A) => These<E1, A1>, |
| 53 | onBoth: (a: A, e: E) => These<E2, A2>, |
| 54 | onFail: (e: E) => These<E3, A3>, |
| 55 | ) { |
| 56 | return (self: These<E, A>): These<E1 | E2 | E3, A1 | A2 | A3> => foldM_(self, onSuccess, onBoth, onFail) |
| 57 | } |
| 58 | |
| 59 | export function map_<E, A0, A>(self: These<E, A0>, f: (a: A0) => A) { |
| 60 | return foldM_( |
nothing calls this directly
no test coverage detected
searching dependent graphs…