How you will update a Component's state?

We update state by calling this.setState(), this causes our component to re-render.

this.setState({showComments:true})
Will only update the properties an argument, not replace the entire state object.
How is state available, and what is it by default?
this.state == null

Comments

Archive

Contact Form

Send