Replies: 2 comments 7 replies
-
| No, since wrapping any React component in  Use your best judgement on what makes sense at which point in your applications, no fixed rules of always or never doing something. | 
Beta Was this translation helpful? Give feedback.
                  
                    4 replies
                  
                
            -
| I saw many complaints about Redux hooks . In my opinion, there is only one reason I would not use useSelector: it makes the Redux logic more tightly coupled to the component. | 
Beta Was this translation helpful? Give feedback.
                  
                    3 replies
                  
                
            
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment
  
        
    
Uh oh!
There was an error while loading. Please reload this page.
-
As it says in the title, if you are refactoring old(er) code that uses
connectfrom:To use the hooks API like:
Is it recommended to (in general) always wrap this resulting
ConnectedMyComponentinReact.memo()since that is one of the optimizations thatconnectwas doing before in the original code?react-redux/src/components/connect.tsx
Line 787 in 70ecef8
If so, is this something that'd make sense being added to the style guide, maybe under Priority B Rules: Strongly Recommended?
Beta Was this translation helpful? Give feedback.
All reactions