(I initially had a huge diff that converted ChatThreadList to a functional component and added various memoizations. However, I realized that diff would be pretty difficult to review so I'm breaking down the refactor into hopefully easier to review pieces.)
This diff is just one step in the process of converting ChatThreadList into a functional component. When this work is done, we will be able to avoid a lot of re-rendering and hopefully improve performance quite a bit.
In subsequent diffs will
- Lift up callbacks related to search
- Lift up "search-related" JSX
- etc.. continue turning ChatThreadList into a functional component so we can more precisely memoize things, particularly ChatThreadListItems.
Depends on D9132