← React Intermediate Questions - Set 11 Q105

How do you prevent a component from rendering?

React Intermediate Questions - Set 11

Example

if (!user) return null;              // render nothing
const Row = memo(RowBase);           // skip when props match

What to notice

← Back to the question list