4 ms·
> relied on jquery. So if that's the case and we must use some React, what can I do to use it in the simplest and clearest way possible? The answer to that que
by schwartzworld 4y ago
> relied on jquery. So if that's the case and we must use some React, what can I do to use it in the simplest and clearest way possible?
The answer to that question has been the same as long as I've been using react. Represent most of your app logic in pure functions. This has been the React team's recommendation, pretty much since the beginning.
Once you get hit to the idea of making everything a function, it pays to learn some functional programming design patterns. This increases your vocabulary for abstracting your application logic into a function.
Once almost everything lives in functions, your react components should really only care about managing the view.