Created
April 24, 2018 14:03
-
-
Save andyfangdz/f9b8c1af65dfa511164a898c577f33bd to your computer and use it in GitHub Desktop.
Debug shouldComponentUpdate
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
shouldComponentUpdate(nextProps, nextState) { | |
for (let key in this.props) { | |
if (this.props[key] !== nextProps[key]) { | |
console.log(key); | |
} | |
} | |
return true; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment