SyntaxFix
Write A Post
Hire A Developer
Questions
Another way is calling setState, AND preserve state:
setState
this.setState(prevState=>({...prevState}));