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
When Teller first loads up, it will load with a DataState of "none". Teller internally requires this state so the state machine can move to valid nodes when you set requirements on the Repository.
However, the UI of the app should not be observing this none state. Why? Because your app might have something like an animation in your app that switches between states. Animation plus a very fast (milliseconds) observing of DataState in Teller between the "none" state and a valid state with a cache causes your UI to have a weird flicker effect in it.
Proposal
When a DataState is in the "none" state, do not deliver that to observers. Let them wait those few milliseconds until the cache is observed and the UI can receive a real response.
What I expect to happen after this change
If we had an example app in this repo, before this fix, you would observe a Teller repository. You would receive a DataState of type none and then very quickly after, you would receive a DataState not of type none. After this fix, you would only receive a DataState not of type none and the none type is ignored.
The text was updated successfully, but these errors were encountered:
When Teller first loads up, it will load with a DataState of "none". Teller internally requires this state so the state machine can move to valid nodes when you set requirements on the Repository.
However, the UI of the app should not be observing this none state. Why? Because your app might have something like an animation in your app that switches between states. Animation plus a very fast (milliseconds) observing of DataState in Teller between the "none" state and a valid state with a cache causes your UI to have a weird flicker effect in it.
Proposal
When a DataState is in the "none" state, do not deliver that to observers. Let them wait those few milliseconds until the cache is observed and the UI can receive a real response.
What I expect to happen after this change
If we had an example app in this repo, before this fix, you would observe a Teller repository. You would receive a DataState of type none and then very quickly after, you would receive a DataState not of type none. After this fix, you would only receive a DataState not of type none and the none type is ignored.
The text was updated successfully, but these errors were encountered: