标签: rxjs scala.js
给出一个scala.concurrent.Future [Int]是否可以将其转换为RxPromise [Int]?
答案 0 :(得分:0)
我能够通过添加以下隐式函数进行转换:
implicit def toRxPromise[T](fut: Future[T]): RxPromise[T] = Observable.fromPromise(fut.toJSPromise).toPromise