Created
December 14, 2019 22:29
-
-
Save juliuscanute/173243c0ebfeefd22e44b3bef663f4a6 to your computer and use it in GitHub Desktop.
Display progress indicator during data retrieval view model
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class _ViewModel { | |
| final Store<EmotionAppState> store; | |
| const _ViewModel({this.store}); | |
| static _ViewModel fromStore(Store<EmotionAppState> store) { | |
| return _ViewModel(store: store); | |
| } | |
| bool isLoading() => !store.state.loadComplete; | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment