Sha256: 93fe33531b0daaf4a520c87abd34f9891be40cb1dc654d67efa0ac7aa5108bc0
Contents?: true
Size: 304 Bytes
Versions: 760
Compression:
Stored size: 304 Bytes
Contents
import {useState} from 'react'; const useCollapsible = (initial= true) => { const [collapsed, setCollapsed] = useState(initial) const toggle = () => setCollapsed((prev) => !prev) return [ collapsed, toggle, setCollapsed as any, ] } export default useCollapsible
Version data entries
760 entries across 760 versions & 1 rubygems