HomePhabricator
Diffusion Comm fc4af3014583

[native] Lift `component[DidMount/WillUnmount]` lifecycle methods to…

Description

[native] Lift component[DidMount/WillUnmount] lifecycle methods to useEffect in ConnectedChatThreadList

Summary:
Replace componentDidMount and componentWillUnmount with a useEffect in ConnectedThreadList. These lifecycle methods effectively add and remove listeners.

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.


Depends on D9188

Test Plan: ChatThreadList + search experience continue to work as expected.

Reviewers: ginsu, tomek, rohan, ashoat

Reviewed By: ashoat

Differential Revision: https://phab.comm.dev/D9189