Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: improve useColorScheme subscription efficiency (#38001)
Summary: motivation: re-rendering `useColorScheme()` hook with what is on the main branch means there is a subscribe + unsubscribe dance happening. related docs: https://react.dev/reference/react/useSyncExternalStore#my-subscribe-function-gets-called-after-every-re-render ## Changelog: <!-- Help reviewers and the release process by writing your own changelog entry. Pick one each for the category and type tags: [INTERNAL] [CHANGED] - improve useColorScheme subscription efficiency For more details, see: https://reactnative.dev/contributing/changelogs-in-pull-requests Pull Request resolved: #38001 Test Plan: tested locally in an app Reviewed By: rshest Differential Revision: D49008053 Pulled By: javache fbshipit-source-id: f8a9fc8950277e2bae8bd8774bf21312a67d46d5
- Loading branch information