diff --git a/packages/react-native/React/Base/RCTJSScriptLoaderModule.h b/packages/react-native/React/Base/RCTJSScriptLoaderModule.h deleted file mode 100644 index f05d361a579411..00000000000000 --- a/packages/react-native/React/Base/RCTJSScriptLoaderModule.h +++ /dev/null @@ -1,22 +0,0 @@ -/* - * Copyright (c) Meta Platforms, Inc. and affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */ - -@class RCTSource; - -NS_ASSUME_NONNULL_BEGIN - -/** - * This protocol should be adopted when a turbo module needs to tell React Native to load a script. - * In bridge-less React Native, it is a replacement for [_bridge loadAndExecuteSplitBundleURL:]. - */ -@protocol RCTJSScriptLoaderModule - -@property (nonatomic, copy) void (^loadScript)(RCTSource *source); - -@end - -NS_ASSUME_NONNULL_END diff --git a/packages/react-native/ReactCommon/react/bridgeless/platform/ios/Core/RCTInstance.mm b/packages/react-native/ReactCommon/react/bridgeless/platform/ios/Core/RCTInstance.mm index 872647242a43ba..a30f029e65f022 100644 --- a/packages/react-native/ReactCommon/react/bridgeless/platform/ios/Core/RCTInstance.mm +++ b/packages/react-native/ReactCommon/react/bridgeless/platform/ios/Core/RCTInstance.mm @@ -19,7 +19,6 @@ #import #import #import -#import #import #import #import @@ -259,12 +258,6 @@ - (Class)getModuleClassFromName:(const char *)name - (void)_attachBridgelessAPIsToModule:(id)module FB_OBJC_DIRECT { __weak RCTInstance *weakInstance = self; - if ([module respondsToSelector:@selector(setLoadScript:)]) { - ((id)module).loadScript = ^(RCTSource *source) { - [weakInstance loadScriptFromSource:(source)]; - }; - } - if ([module respondsToSelector:@selector(setDispatchToJSThread:)]) { ((id)module).dispatchToJSThread = ^(dispatch_block_t block) { __strong __typeof(self) strongSelf = weakInstance;