Browse files

iOS: RCTSurface needs to re-register its root view on bridge reload

Summary: When reloading JS during development, surface needs to make sure the root view gets re-registered before attempting to remount it. This fixes redbox on JS reload.

Reviewed By: shergin

Differential Revision: D7170416

fbshipit-source-id: c84b999d2cdc35cb9e26feef2a1e1a7ce35cfa70
  • Loading branch information...
fkgozali authored and facebook-github-bot committed Mar 6, 2018
1 parent 48c339d commit 2e51fa5f5d4f229329ae457ab1a77ba5bcea0448
Showing with 1 addition and 0 deletions.
  1. +1 −0 React/Base/Surface/
@@ -209,6 +209,7 @@ - (void)handleBridgeDidLoadJavaScriptNotification:(NSNotification *)notification
if (isRerunNeeded) {
[self _registerRootView];
[self _run];

0 comments on commit 2e51fa5

Please sign in to comment.