StateHook<T> class

State hook for managing component state

Inheritance

Constructors

StateHook(T _value, String? _name, dynamic _scheduleUpdate())
Create a state hook

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
state → T
Get the current value
no setter

Methods

dispose() → void
Clean up the hook when component unmounts
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
setState(T newValue) → void
Set the value and trigger update
toString() String
A string representation of this object.
override

Operators

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