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 theBuildContext
along with thestate
and is responsible for executing in response tostate
changes. -
BlocWidgetSelector<
S, T> = T Function(S state) -
Signature for the
selector
function which is responsible for returning a selected value,T
, based onstate
.