Pure Functional Component
Simply use React.memo(FUNCTIONAL_COMPONENT)
React.memo(FUNCTIONAL_COMPONENT)
React.PureComponent is silver
React.PureComponent
React.memo(...) is golden.
React.memo(...)
React.PureComponent optimizes re-rendring in ES6 class components
React.memo(...) optimizes re-rendring in functional components
ref : https://blog.bitsrc.io/improve-performance-in-react-functional-components-using-react-memo-b2e80c11e15aarrow-up-right
Last updated 5 years ago