Skip to content

Commit

Permalink
Ensure connectAdvanced only re-renders if derived props change
Browse files Browse the repository at this point in the history
  • Loading branch information
markerikson committed Nov 11, 2018
1 parent 8fb8a39 commit 8d0cb87
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions src/components/connectAdvanced.js
Expand Up @@ -203,11 +203,7 @@ export default function connectAdvanced(
store
)

if (pure) {
return this.selectChildElement(derivedProps, forwardedRef)
}

return <FinalWrappedComponent {...derivedProps} ref={forwardedRef} />
return this.selectChildElement(derivedProps, forwardedRef)
}

render() {
Expand Down

0 comments on commit 8d0cb87

Please sign in to comment.