3 ms·
A bit of a side-topic but I am not sure why people use flux/redux and it is constantly mentioned when talking about react. We have over 20 very complex project
by _pdp_ 8y ago
A bit of a side-topic but I am not sure why people use flux/redux and it is constantly mentioned when talking about react.
We have over 20 very complex projects built in react with no flux. The whole state is managed by react itself and some helpful decorators. You could just easily not use flux/redux - the article should not mention it.
- iliaznk 8y agoPeople use Redux or any other state management solutions for the same reason they use frameworks and libraries in the first place – all the tough design decisions have been made for them, they just have to follow the rules. Of course you can do with React's internal state alone, but do get it right for complex apps it takes some prior experience and knowledge. Could you elaborate a bit on what those decorators you mentioned are?
- _pdp_ 8y agoThis not my point - my point is that although it is optional it is mentioned as the defacto standard. I don't think it is because it complicates things way to much. I cannot enumerate all decorators in this comment but we have one called useGlobalState where you pass several prop names and a scope name and in return it manages those props for your like any other controlled component. It is fast and it is effective in what it does. There are a few others that are more specific.