-
-
Notifications
You must be signed in to change notification settings - Fork 287
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Correct use of provider and notify #2439
Comments
💯 Especially the |
That is what I plan to implement regarding product refresh:
@M123-dev Any remark or suggestion? |
Not really the plan looks good to me, just to number 5, even though it's nearly instant I would still add a loading indicator in case due to some bad circumstances it takes a few seconds more. |
@M123-dev I agree, though it would be a bit lazy to put a |
Maybe something like this "shimmer | Flutter Package" https://pub.dev/packages/shimmer But as you said that's not a priority in any terms |
Fixed by #3018. |
Problem
We experience every day issues regarding products or list not being refreshed.
Most of the time, we just use provider for
static
fields: let's get the database withcontext.watch<LocalDatabase>()
.And if we notify the
LocalDatabase
, sometimes it's good (actually it's always good) but sometimes there are side-effects (like not necessary page refreshes that don't look good).Proposed solution
I think it's time to refactor our use of providers.
If we focus on products, I think we have two strong needs:
Solutions would include:
select
, in order to say "on this page the rest of the world may change but I only care about this product"Additional context
Part of
The text was updated successfully, but these errors were encountered: