React Component Lifecycle

Creation:

Update:

1. Trigger by parent:

2. Trigger by internal change (e.g. state change):

 

PureComponent overwrites shouldComponentUpdate, it checks state and props change in shouldComponentUpdate, it there is no change, update would be cancelled, all updates for its child are cancelled too

posted on 2018-07-29 10:51  OpenZigCoder  阅读(120)  评论(0)    收藏  举报

导航