When would you use App state or...
When would you use App state or...
Here is a concise answer to your question about when to use ephemeral state vs app state in Flutter:
Use ephemeral state when the state is:
setState()Examples of ephemeral state include:
PageViewBottomNavigationBar[1]For ephemeral state, use StatefulWidget and setState() to rebuild the widget tree when the state changes[1][2].
Use app state when the state:
setState() becomes unwieldyExamples of app state include:
senior