<p>When to useMemo and useCallback and performance tips</p>
<p>Best piece of advice extracted from article:
MOST OF THE TIME YOU SHOULD NOT BOTHER OPTIMIZING UNNECESSARY RERENDERS. React is VERY fast and there are so many things I can think of for you to do with your time that would be better than optimizing things like this. In fact, the need to optimize stuff with what I'm about to show you is so rare that I've literally never needed to do it in the 3 years I worked on PayPal products and the even longer time that I've been working with React.
(edited)</p>
<p>Also:
What's the point?
The point is this:
<em>Performance optimizations are not free. They ALWAYS come with a cost but do NOT always come with a benefit to offset that cost.</em>
Therefore, optimize responsibly.</p>