mirror of
https://github.com/status-im/react-native.git
synced 2025-02-26 08:05:34 +00:00
Summary: I need to do some refactoring of what happens when a ReactRootView is attached/detached from the window. In doing so, I found ReactRootView is way more complicated than it needs to be and very hard to understand. This simplifies it while maintaining functionality. Basically: - When you start a react application, if the root view is measured, we attach it to the instance. - If it wasn't measured, we do nothing - In onMeasure, if we have a ReactInstanceManager, but are not attached to it, attach to it. None of this needs to depend on whether we're attached to the window or whether an attach is scheduled afaict. Reviewed By: dmmiller Differential Revision: D3260056 fb-gh-sync-id: 974c19ed75a07f83299472f75346bd6be7414128 fbshipit-source-id: 974c19ed75a07f83299472f75346bd6be7414128