Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make sure the Native RuntimeScheduler is initialized on Old Arch
Summary: Fixes #35778 We got reports of regressions on `useEffect` starting from 0.69+ when on Hermes. The issue seems to be caused by a bump of the `scheduler` package from 0.20 to 0.21. In [email protected], the method `setImmediate` gets called if available (see facebook/react#20834). This causes React Native to use Microtasks which ends up in changing the semantic of useEffect. The solution is to use the Native RuntimeScheduler properly. On Paper specifically, we never initialized it as it's effectively initialized by the TurboModuleManagerDelegate. Here I trigger the initialization of it on Paper as well. Changelog: [Android] [Fixed] - Make sure the Native RuntimeScheduler is initialized on Old Arch Reviewed By: sammy-SC Differential Revision: D46024807 fbshipit-source-id: 7287a5a982fe660aca8fc20e9e5c6840b5e5f42b
- Loading branch information