dispose method
This is called on Ref.dispose. You can override this method to dispose resources.
Implementation
@override
void dispose() {
super.dispose();
// This will cause the temporary providers to be disposed
// after this notifier is disposed.
// The reason we do this is because we want to show the correct
// event chain in the tracing.
dependents.addAll(_providers.values.map((provider) {
return _container!.anyNotifier<BaseNotifier<T>, T>(provider);
}));
_providers.clear();
state.clear();
}