(useReducerOnce reducer initial k)
Like useReducer, but maintains your state across hot-reloads. k
is a globally
unique key to ensure you always get the same state back.
Example: (useReducerOnce reducer initial ::counter)
Like useReducer, but maintains your state across hot-reloads. `k` is a globally unique key to ensure you always get the same state back. Example: `(useReducerOnce reducer initial ::counter)`
(useStateOnce initial k)
Like useState, but maintains your state across hot-reloads. k
is a globally
unique key to ensure you always get the same state back.
Example: (useStateOnce 0 ::counter)
Like useState, but maintains your state across hot-reloads. `k` is a globally unique key to ensure you always get the same state back. Example: `(useStateOnce 0 ::counter)`
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close