DEV Community

Mohamed Fahath
Mohamed Fahath

Posted on

Answer: Setting provider value in FutureBuilder

That exception arises because you are synchronously modifying a widget from its descendants.

This is bad, as it could lead to an inconsistent widget tree. Some widget. may be built widgets using the value before mutation, while others may be using the mutated value.

The solution is to remove the…

Top comments (0)