Skip to content

Commit

Permalink
fix(taro-redux): close #2595,reopen #1125
Browse files Browse the repository at this point in the history
修复 redux 引起的组件更新不能被 shouldComponentUpdate 中断。
  • Loading branch information
Chen-jj committed Mar 26, 2019
1 parent 0c14d33 commit c93dbd5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/taro-redux/src/connect/connect.js
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ export default function connect (mapStateToProps, mapDispatchToProps) {
if (isChanged) {
this.prevProps = prevProps
this._unsafeCallUpdate = true
this.forceUpdate(() => {
this.setState({}, () => {
delete this._unsafeCallUpdate
})
}
Expand Down

0 comments on commit c93dbd5

Please sign in to comment.