Skip to content
This repository has been archived by the owner on Dec 12, 2021. It is now read-only.

Revert #13 where scheduler is applied to inputs that cause delayed UI rendering #18

Merged
merged 1 commit into from
Oct 25, 2019

Conversation

inamiy
Copy link
Owner

@inamiy inamiy commented Oct 25, 2019

Related: #12 #13

This PR reverts #13 where scheduler is also applied to external inputs.
Unfortunately, this caused delayed UI rendering that becomes annoying especially in SwiftUI which uses synchronous UI binding update.

Since inputs.receive(on: scheduler) is not a requirement for avoiding synchronous feedback crash (though it improves thread safety), this PR will apply scheduler only for effectInputs.

Downside of this change is that user needs to be aware of thread-safety issue as commented in documentation:

NOTE: This (`scheduler`) should be on the same thread as `inputs`

But still, having scheduler parameter is (probably) better than going back before #12 .

@inamiy inamiy merged commit 2aa0d0c into master Oct 25, 2019
@inamiy inamiy deleted the fix-scheduler branch October 25, 2019 02:41
inamiy added a commit that referenced this pull request Jan 25, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant