Ask a question to get started
Enter to send•Shift+Enter new line
Functional update. The updater receives the current snapshot and MUST return a new object. Returning the same reference is a no-op.
updater
setState(updater: (previous: T) => T)
(previous: T) => T