HookUtils class abstract final

Utility functions for SetupWidget hooks and lifecycle management.

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Methods

onActivated(void callback()) → void
Registers a callback to be called when the widget is activated.
onChangedDependencies(void callback()) → void
Registers a callback to be called when widget dependencies change.
onDeactivated(void callback()) → void
Registers a callback to be called when the widget is deactivated.
onMounted(void callback()) → void
Registers a callback to be called when the widget is mounted.
onUnmounted(void callback()) → void
Registers a callback to be called when the widget is unmounted.
onUpdated(void callback()) → void
Registers a callback to be called when the widget is updated.
use<T>(SetupHook<T> hook) → T
Creates a hook that persists across rebuilds and hot reloads.
useContext() BuildContext
Gets the current BuildContext from the SetupWidget.
useSetupContext() JoltSetupContext<SetupWidget>
Gets the current JoltSetupContext.