components/mediator library

Mixins

Mediator<T extends StatefulWidget>
A mediator is a class that manages the state of the application. Use this mixin in your stateful widget to manage one or more states, saving you from writing the boilerplate code to manage states. Using the mediator, you don't have to manually manage success, loading, and error states. Just dispatch a command and use the state getter to get the state. The mediator handles the state lifecycle automatically.