Skip to content
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

State Management issue #43

Open
MedjadderAymen opened this issue Feb 3, 2022 · 2 comments
Open

State Management issue #43

MedjadderAymen opened this issue Feb 3, 2022 · 2 comments

Comments

@MedjadderAymen
Copy link

hello, I have been working with the library this morning but I faced an error in the package when I use data from a provider. so the scenario is the next: I have a list of items stocked in a provider (cart) every time the user picks a new item I add it to the stack in the provider. each item has a quantity so the user can increment/decrement. I was using your library I found that in case the user delete an item from the stack. the library keeps an old value. ex: (item 1 - q = 50 / item 2 - q10) if I delete item 1, the quantity of item 2 (using the library) change to 50!! I checked my provider, and everything is good. the problem is within the library it keeps a trace of an old stack so it still uses the index of the old library.

hope you fix this.

@Abhilash-Chandran
Copy link
Owner

HI @MedjadderAymen ,

Thanks for taking time to report an issues.
But I am not quite sure if I understood your issue.
Could you provide a simple example code where I reproduce this issue.

@Cloyd1234
Copy link

I am also getting this issue when using this package with ListView.builder.

For example.
Row 1 Name: Item 1, Qty: 5
Row 2 Name: Item 2, Qty: 10
Row 3 Name: Item 3, Qty: 15

(where Qty is the textfield created by this package incremented)

When I try to delete the Row 2 from my List of Maps using the remove method, the output below appears:
Row 1 Name: Item 1, Qty: 5
Row 2 Name: Item 3, Qty: 10

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants