You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi,
Id like to ask, if its possible for HandlerScheduler to check wether it "needs to change threads", i.e. avoid posting if already on main thread. unnecessarily
This can manifest it self, when using observable mapped to Started, Success, Error events, and UI (main thread) subscribes to the observable (and Started is created via startWith()), which then posts the Started emit for no reason.
I know you can do this by rearranging the operators like
But that ties it to main thread from from within of the api. I think in this case the subscriber should decide, (which we already do most of the time - which leaves the Started to be posted). Say if that was a network observable, and you want to compose 2 of them some how, which gives them implicit scheduler unneccesarily)
The text was updated successfully, but these errors were encountered:
Uh oh!
There was an error while loading. Please reload this page.
Hi,
Id like to ask, if its possible for HandlerScheduler to check wether it "needs to change threads", i.e. avoid posting if already on main thread. unnecessarily
This can manifest it self, when using observable mapped to Started, Success, Error events, and UI (main thread) subscribes to the observable (and Started is created via startWith()), which then posts the Started emit for no reason.
I know you can do this by rearranging the operators like
But that ties it to main thread from from within of the api. I think in this case the subscriber should decide, (which we already do most of the time - which leaves the Started to be posted). Say if that was a network observable, and you want to compose 2 of them some how, which gives them implicit scheduler unneccesarily)
The text was updated successfully, but these errors were encountered: