ListenableProvider<T extends Listenable?> constructor
ListenableProvider<T extends Listenable?> ({})
Creates a Listenable using create
and subscribes to it.
dispose
can optionally passed to free resources
when ListenableProvider is removed from the tree.
create
must not be null
.
Implementation
ListenableProvider({
Key? key,
required Create<T> create,
Dispose<T>? dispose,
bool? lazy,
TransitionBuilder? builder,
Widget? child,
}) : super(
key: key,
startListening: _startListening,
create: create,
dispose: dispose,
lazy: lazy,
builder: builder,
child: child,
);