--- title: Set State with this.setState localeTitle: 使用this.setState设置State --- ## 使用this.setState设置State #### 提示1: ```JSX class MyComponent extends React.Component { constructor(props) { super(props); this.state = { name: 'Initial State' }; this.handleClick = this.handleClick.bind(this); } handleClick() { // change code below this line // Update the state data by using "this.setState()" method. // You can look to the sample inside the description for calling "setState()" method. // change code above this line } render() { return (