【发布时间】:2017-08-26 21:32:11
【问题描述】:
我有一个实时搜索,但如果由于某种原因 forkJoin 失败,一切都会停止工作。我在错误后尝试寻找的任何新词都不起作用。如何显示错误并正常恢复流,以便我可以搜索其他单词?
this.search$
.distinctUntilChanged()
.switchMap((query) => Rx.Observable.forkJoin(sources)) // If this fails the search stops working
.subscribe((results) => console.log(results));
【问题讨论】:
标签: angular react-native stream rxjs reactjs-flux