select icon indicating copy to clipboard operation
select copied to clipboard

Almost ineffective useMemo?

Open bahmannejati opened this issue 3 years ago • 0 comments

Hi everyone, I saw a useMemo with children props as its dependency, but react renews children references in every render, so is this useMemo used just to prevent rerender caused by internal state changes? I mean whenever the parent component re-renders, Select re-renders too, it's a little strange

https://github.com/react-component/select/blob/95aa5b937b871c8eac0283d62d14d9b6c6acadac/src/generate.tsx#L454

bahmannejati avatar Oct 21 '21 06:10 bahmannejati