onMount method
Called when the resource is mounted to the widget tree.
This method is invoked after the resource is created and the JoltProvider widget is mounted. Use this to:
- Initialize resources (timers, subscriptions, etc.)
- Start background processes
- Set up listeners or observers
The context parameter provides access to the widget tree context.
Example
@override
void onMount(BuildContext context) {
super.onMount(context);
_subscription = someStream.listen(_handleEvent);
}
Implementation
void onMount(BuildContext context) {}