onRemoveListener method
A life-cycle for whenever a listener is removed from the provider.
See also:
- onAddListener, for when a listener is added
Implementation
@override
void onRemoveListener(void Function() cb) {
_onRemoveListeners ??= [];
_onRemoveListeners!.add(cb);
}