store_keeper library

Classes

BuildOn
A stream builder like widget that accepts mutations and rebuilds after their execution.
Interceptor
Implementation of this class can be used to act before or after a mutation execution.
Mutation<T extends Store>
An implementation of this class holds the logic for updating the Store.
NotifyOn
Helper widget that executes the provided callbacks with context on execution of the mutations. Useful to show SnackBar or navigate to a different route after a mutation.
Store
App's store should extend this class. An instance of this class is given to StoreKeeper while initialization.
StoreKeeper
The coordinating widget that keeps track of mutations and the notify the same to the listening widgets.

Mixins

SideEffects<ON>
Secondary mutation executed based on the result of the first. Similar to chaining actions in Redux. For example, an http request will have a success or a fail side effect after request is complete.

Typedefs

ContextCallback = void Function(BuildContext context, Mutation<Store> mutation)
Function signature for the callback with context.
MutationBuilder = Mutation<Store> Function()
Function signature for mutations that has deferred execution. Mutation.later accepts functions with this signature.