react
react copied to clipboard
update checkbox defaultChecked , it doesn't work
It's not a bug. See the docs https://facebook.github.io/react/docs/forms.html#default-value
The
defaultValueanddefaultCheckedprops are only used during initial render.
As mentioned, this is working as intended, you actually want a controlled component.
thanks @nikolaymatrosov @zpao
use checked property works, see here
react is the most stupid thing i have ever seen