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
Currently whenever we call Store.stream(StoreRequest.cached...)...) the only Loading we get is that of a Fetcher. This means that if we create a UI state folding the stream of StoreResponses, we can't really know when we are loading stuff from the SourceOfTruth, which is usually fast but not instant. Often we want to show a loading not only when we are fetching data but also while retrieving data from the source of truth.
The solution would be to add the emission of a Loading store response with the origin set to SourceOfTruth which retrieving data. This way we can be more granular the way we handle loading states.
Note: This refers to Store4 (4.0.5).
The text was updated successfully, but these errors were encountered:
I think the initial concern was around disk emitting fairly quickly leading to ui flashing, I'm ok with this going in with some flag in the request that enables it. Let me think about a clean way to do it. Happy to accept a PR as well
Currently whenever we call
Store.stream(StoreRequest.cached...)...)
the onlyLoading
we get is that of aFetcher
. This means that if we create a UI state folding the stream ofStoreResponse
s, we can't really know when we are loading stuff from the SourceOfTruth, which is usually fast but not instant. Often we want to show a loading not only when we are fetching data but also while retrieving data from the source of truth.The solution would be to add the emission of a
Loading
store response with the origin set toSourceOfTruth
which retrieving data. This way we can be more granular the way we handle loading states.Note: This refers to Store4 (4.0.5).
The text was updated successfully, but these errors were encountered: