Version: 9.0.7
BLoC pattern
Also you are able to use the BLoC pattern with flutter_meedu.
Just create a class that extends of Bloc
and define the event and state class.
note
If you want to use the freezed
package to generate your events using Union types
and Sealed classes. Don't worry. The Bloc
class is totally compatible with that.
Next you need to create a StateNotifierProvider
and use the Consumer
widget to listen the changes in your state.
note
The Bloc
class extends of StateNotifier
so you are able to use
the .select
and .when
filters in your Consumers.