This hook is designed for boolean state values. It comes with a toggle method that helps to speed up development.
Values
isToggled:
Boolean toggle value
setIsToggled:
Method to manually set the toggle value
toggle:
Method to toggle the boolean state
Arguments
initial:
The initial value that get's passed on to state