use-toggle-react
v1.0.0
Published
Custom toggle hook for react
Downloads
6
Readme
usetoggle-react - Demo
Toggle custom hook for react
example useage
const [isVisble, toggle] = useToggle(false);
<button onClick={toggle}>{isVisble ? "Close" : "Open"}</button>
{ isVisble && <div>Element</div> }