flutter_bloc_hooks library

Functions

useBloc<B extends BlocBase>() → B
useBlocListener<B extends BlocBase<S>, S>(BlocWidgetListener<S> listener) → void
useBlocSelector<B extends BlocBase<S>, S, T>(BlocWidgetSelector<S, T> selector) → T
useBlocState<B extends BlocBase<S>, S>() → S

Typedefs

BlocWidgetListener<S> = void Function(BuildContext context, S state)
Signature for the listener function which takes the BuildContext along with the state and is responsible for executing in response to state changes.
BlocWidgetSelector<S, T> = T Function(S state)
Signature for the selector function which is responsible for returning a selected value, T, based on state.