use-set-state
Manages state with setState-like API
Source
Docs
PackageIcon
Usage
The use-set-state hook works similarly to how this.setState works in class components – it shallow merges the state partial
into the current state.
Note that it can work only with objects; primitive values and arrays are not supported:
Definition
Exported types
UseSetStateCallback and UseSetStateReturnValue types are exported from the @mantine/hooks package;
you can import them in your application: