React.useMemo() serves as a memoized/computed value. It works with a dependency array and re-computes once a dependency changes. Its typical usages are filtered data or heavier calculations, which you don't want to run on each re-render and don't want to store in state, as that value is dynamic.
Filtered animals: dog, dragon, dinosaur