From 97e3c091f84d86cfb6d07399b131ff4bf93f67fd Mon Sep 17 00:00:00 2001 From: Marc Horowitz Date: Mon, 26 Sep 2016 16:01:44 -0700 Subject: [PATCH] Sync support for new ios bridge Reviewed By: javache Differential Revision: D3897528 fbshipit-source-id: f30d2b1c490c1a9f7fc1f136858e6c7a146b9ca2 --- React/Base/RCTBridgeDelegate.h | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/React/Base/RCTBridgeDelegate.h b/React/Base/RCTBridgeDelegate.h index f29c7aae4..f866c94cf 100644 --- a/React/Base/RCTBridgeDelegate.h +++ b/React/Base/RCTBridgeDelegate.h @@ -63,6 +63,15 @@ */ - (NSArray *)whitelistedModulesForBridge:(RCTBridge *)bridge; +/** + * When loading initial JavaScript, do so synchronously when the bridge is created iff + * this returns true. Otherwise, the JS will be fetched on a network thread, and + * executed on the JS thread. Currently used only by C++ bridge. + * + * @experimental + */ +- (BOOL)shouldBridgeLoadJavaScriptSynchronously:(RCTBridge *)bridge; + /** * When initializing native modules that require main thread initialization, the bridge * will default to dispatch module creation blocks asynchrously. If we're blockingly