flutter_reduct library

Flutter Widgets for Reduct Library.

Classes

AtomBuilder<S>
AtomBuilder handles building a widget in response to new value. AtomBuilder is analogous to StreamBuilder but has simplified API to reduce the amount of boilerplate code needed as well as atom-specific performance improvements.
AtomListener<S>
Takes a AtomListener and an atom and invokes the listener in response to value changes in the atom. It should be used for functionality that needs to occur only in response to a value change such as navigation, showing a SnackBar, showing a Dialog, etc...
BuilderBase<S>
Base class for widgets that build themselves based on interaction with a specified atom.
ListenerBase<S>
Base class for widgets that listen to state changes in a specified atom.

Typedefs

WidgetBuilder<S> = Widget Function(BuildContext context, S value)
Signature for the builder function which takes the BuildContext and value and is responsible for returning a widget which is to be rendered. This is analogous to the builder function in StreamBuilder.
WidgetListener<S> = void Function(BuildContext context, S value)
Signature for the listener function which takes the BuildContext along with the value and is responsible for executing in response to value changes.