React checkbox doesn’t toggle
I think I see what’s happening. You click the button, and it toggles is_checked, which either checks or unchecks the box. But that ends up triggering an onChange for the checkbox, which also toggles the state… You’ve actually coded an infinite loop. Although, since React batches/debounces setState operations, your code won’t lock your page up. … Read more