etr2460 commented on issue #16553:
URL: https://github.com/apache/superset/issues/16553#issuecomment-910933134


   Yup @eschutho , totally agree about clarifying when to use Redux vs. local 
state. I think we'll probably write a whole dos and don'ts for that question, 
although it's a bit too low level for this summary proposal.
   
   That said, if you asked me to chime in, i'd probably say:
   - state used by only one component should always be local, even if it's 
coming from an api (since it's probably good to have updated state in cases 
where a component is unrendered then rerendered)
   - state used by more than one component should always be in Redux (I feel 
less strongly here, and could see arguments either way, but having a hard and 
fast rule might make our lives easier and prevent that grey area from existing)
   
   I'm not a huge fan of Redux anyway, so i'll leave the decision making 
regarding state to those with more experience, more passion, and less angst 😅 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to