diff --git a/packages/react-native/Libraries/AppDelegate/RCTAppDelegate.mm b/packages/react-native/Libraries/AppDelegate/RCTAppDelegate.mm index 12f5947329379b..711c56115fd434 100644 --- a/packages/react-native/Libraries/AppDelegate/RCTAppDelegate.mm +++ b/packages/react-native/Libraries/AppDelegate/RCTAppDelegate.mm @@ -87,10 +87,8 @@ - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:( RCTFabricSurface *surface = [_reactHost createSurfaceWithModuleName:self.moduleName initialProperties:launchOptions]; - RCTSurfaceHostingProxyRootView *surfaceHostingProxyRootView = [[RCTSurfaceHostingProxyRootView alloc] - initWithSurface:surface - sizeMeasureMode:RCTSurfaceSizeMeasureModeWidthExact | RCTSurfaceSizeMeasureModeHeightExact - moduleRegistry:[_reactHost getModuleRegistry]]; + RCTSurfaceHostingProxyRootView *surfaceHostingProxyRootView = + [[RCTSurfaceHostingProxyRootView alloc] initWithSurface:surface moduleRegistry:[_reactHost getModuleRegistry]]; rootView = (RCTRootView *)surfaceHostingProxyRootView; #endif diff --git a/packages/react-native/React/Base/Surface/SurfaceHostingView/RCTSurfaceHostingProxyRootView.h b/packages/react-native/React/Base/Surface/SurfaceHostingView/RCTSurfaceHostingProxyRootView.h index f36af0ee7b3350..65d39ba008c72c 100644 --- a/packages/react-native/React/Base/Surface/SurfaceHostingView/RCTSurfaceHostingProxyRootView.h +++ b/packages/react-native/React/Base/Surface/SurfaceHostingView/RCTSurfaceHostingProxyRootView.h @@ -54,9 +54,7 @@ NS_ASSUME_NONNULL_BEGIN /** * Bridgeless mode initializer */ -- (instancetype)initWithSurface:(id)surface - sizeMeasureMode:(RCTSurfaceSizeMeasureMode)sizeMeasureMode - moduleRegistry:(RCTModuleRegistry *)moduleRegistry; +- (instancetype)initWithSurface:(id)surface moduleRegistry:(RCTModuleRegistry *)moduleRegistry; - (instancetype)initWithSurface:(id)surface; diff --git a/packages/react-native/React/Base/Surface/SurfaceHostingView/RCTSurfaceHostingProxyRootView.mm b/packages/react-native/React/Base/Surface/SurfaceHostingView/RCTSurfaceHostingProxyRootView.mm index a7c67cffcc68c5..128b9c2f3eb51b 100644 --- a/packages/react-native/React/Base/Surface/SurfaceHostingView/RCTSurfaceHostingProxyRootView.mm +++ b/packages/react-native/React/Base/Surface/SurfaceHostingView/RCTSurfaceHostingProxyRootView.mm @@ -93,11 +93,9 @@ - (instancetype)initWithBundleURL:(NSURL *)bundleURL return [self initWithBridge:bridge moduleName:moduleName initialProperties:initialProperties]; } -- (instancetype)initWithSurface:(id)surface - sizeMeasureMode:(RCTSurfaceSizeMeasureMode)sizeMeasureMode - moduleRegistry:(RCTModuleRegistry *)moduleRegistry +- (instancetype)initWithSurface:(id)surface moduleRegistry:(RCTModuleRegistry *)moduleRegistry { - if (self = [super initWithSurface:surface sizeMeasureMode:sizeMeasureMode]) { + if (self = [self initWithSurface:surface]) { _moduleRegistry = moduleRegistry; }