alpceylan / flutter-countup

Basic counter widget for flutter.
MIT License
14 stars 23 forks source link

fix(animation): ensure animation reset if values change #3

Closed sommestad closed 4 years ago

sommestad commented 4 years ago

Noticed during additional building & testing that the widget can be re-built with new values, but a re-used state. When that happens, the previous version did not trigger the animation correctly.

This resolves the issue by resetting the animation controller if the state's different from the provided arguments.


Sorry for not catching this in #1.

Also, this replaces #2.

alpceylan commented 4 years ago

Thanks, you helped a lot to this project :D I just merged