Creates a hook like useState but all instances will have a single shared storage
npm install create-global-state-hookCreates a hook like useState but all instances will have a single shared storage
``js
import creteGlobalStateHook from 'crete-global-state-hook'
const useGlobalCounter = createGlobalStateHook(0)
export default function GlobalCounter() {
const [count, setCount] = useGlobalCounter()
return (