You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
constructor(props){super(props);// other codethis.state={count: this.getVal()}}getVal(){returnCounterStore.getCounterValues()[this.props.caption]}onChange(){this.setState({count: this.getVal()});}
在3.1.2的结束部分,你是这么说的:
这里说到两次的重复调用,以及只使用CounterStore.getCounterValues一次。可以使用下面的代码实现:
如果你是指单纯的重复代码,那我觉得这句话是不准确的。如果指的是触发Action的次数,那我的疑惑也就明白了。
The text was updated successfully, but these errors were encountered: