← React Intermediate Questions - Set 4 Q36

How can you prevent a component from re-rendering in React?

React Intermediate Questions - Set 4

Example

const Heavy = memo(function Heavy({ data }) { … });
const data = useMemo(() => build(), [source]);

What to notice

← Back to the question list