flutter_bus library

"flutter_package for An FlutterBus for Flutter apps"

Classes

FlutterBus
A universal FlutterBus pub/sub for Flutter Apps. Use like so FlutterBus.on
FlutterBusBuilder<T>
Widget that builds itself based on the latest typed event published on the FlutterBus.
FlutterBusBuilderState<T>
State class to manager the FlutterBus subscription for a widget

Typedefs

FlutterBusFunction<T> = void Function(T)
Function def for functions that use the Flutter Bus
FlutterBusWidgetBuilder<T> = Widget Function(BuildContext context, T? event)
Signature for strategies that build widgets based on FlutterBus data. The widget gets the build context and the lastEvent published on the FlutterBus. The first build will use the builders' initialData and only for the initialData can the event be null since initialData is not required.