Files
react-native/packages/react-native-fantom
Rubén Norte c925872e72 Throw an error when calling root.render outside of a task (#49003)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/49003

Changelog: [internal]

I was adding a benchmark for rendering thousands of views and it was surprisingly fast, until I realized I wasn't wrapping the call to `root.render` in `runTask`, which means the benchmark wasn't really doing the rendering, only scheduling a microtask that was never executed.

This is a safety mechanism to prevent those mistakes.

Reviewed By: sammy-SC

Differential Revision: D68771170

fbshipit-source-id: 5bd8e6ba9e1168db2320572c99b3a01ebd6aeeed
2025-01-28 07:26:23 -08:00
..