Closed pengzhanlee closed 8 years ago
Hi, all
I dont't want to dispatch an action, it's just a display state for UI Component.
I tried to use setState, and return true in shouldComponentUpdate, but it not work.
<SomeComponent onClick={()=>{ this.setState({ showAnthorComponent: true }); }) }} />
<AnthorComponent show={this.props.showAnthorComponent} />
I found an example in about.js.
Hi, all
I dont't want to dispatch an action, it's just a display state for UI Component.
I tried to use setState, and return true in shouldComponentUpdate, but it not work.
<SomeComponent onClick={()=>{ this.setState({ showAnthorComponent: true }); }) }} />
<AnthorComponent show={this.props.showAnthorComponent} />