Closed OliverJAsh closed 4 years ago
Observables already have a built in method toPromise. However, in fp-ts, Task is preferred over Promise. Therefore I would like to suggest adding a toTask helper:
Observable
toPromise
Task
Promise
toTask
export const toTask = <V>(ob$: RxJS.Observable<V>): T.Task<V> => () => ob$.toPromise();
See #21
Observable
s already have a built in methodtoPromise
. However, in fp-ts,Task
is preferred overPromise
. Therefore I would like to suggest adding atoTask
helper: