mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
Backout "Add warning when a component is loaded with the interop layer"
Summary: Backing out https://github.com/facebook/react-native/pull/50244 as it is causing unexpected issues internally. ## Changelog: [iOS][Changed] - Revert "Add warning when a component is loaded with the interop layer" Reviewed By: cortinico Differential Revision: D72857290 fbshipit-source-id: cfae6ccf85a472ae03983349fc7a2620e157865d
This commit is contained in:
committed by
Facebook GitHub Bot
parent
5fd08ce3de
commit
bd64ec817d
@@ -50,7 +50,6 @@ using namespace facebook::react;
|
||||
{
|
||||
if (self = [super init]) {
|
||||
self.delegate = delegate;
|
||||
RCTNewArchitectureSetMinValidationLevel(RCTNotAllowedInFabricWithoutLegacy);
|
||||
[self _setUpFeatureFlags:releaseLevel];
|
||||
|
||||
auto newArchEnabled = [self newArchEnabled];
|
||||
|
||||
@@ -310,9 +310,6 @@ newArchitectureValidationInternal(RCTLogLevel level, RCTNotAllowedValidation typ
|
||||
case RCTLogLevelFatal:
|
||||
RCTAssert(0, @"%@", msg);
|
||||
break;
|
||||
case RCTLogLevelWarning:
|
||||
RCTLogWarn(@"%@", msg);
|
||||
break;
|
||||
default:
|
||||
RCTAssert(0, @"New architecture validation is only for info, error, and fatal levels.");
|
||||
}
|
||||
@@ -337,7 +334,7 @@ void RCTErrorNewArchitectureValidation(RCTNotAllowedValidation type, id context,
|
||||
|
||||
void RCTLogNewArchitectureValidation(RCTNotAllowedValidation type, id context, NSString *extra)
|
||||
{
|
||||
newArchitectureValidationInternal(RCTLogLevelWarning, type, context, extra);
|
||||
newArchitectureValidationInternal(RCTLogLevelInfo, type, context, extra);
|
||||
}
|
||||
|
||||
void RCTNewArchitectureValidationPlaceholder(RCTNotAllowedValidation type, id context, NSString *extra)
|
||||
|
||||
@@ -141,13 +141,11 @@ static Class<RCTComponentViewProtocol> RCTComponentViewClassWithName(const char
|
||||
// TODO(T174674274): Implement lazy loading of legacy view managers in the new architecture.
|
||||
if (RCTFabricInteropLayerEnabled() && [RCTLegacyViewManagerInteropComponentView isSupported:componentNameString]) {
|
||||
RCTLogNewArchitectureValidation(
|
||||
RCTAreLegacyLogsEnabled() ? RCTNotAllowedInFabricWithoutLegacy : RCTNotAllowedInBridgeless,
|
||||
RCTNotAllowedInBridgeless,
|
||||
self,
|
||||
[NSString
|
||||
stringWithFormat:
|
||||
@"The `%@` component is loaded in the app using the Fabric Interop layer. This is part of the compatibility layer with the Legacy Architecture. If `%@` is a local component, please migrate it to be a Native Component as described at https://reactnative.dev/docs/next/fabric-native-components-introduction. If `%@` is a third party dependency, please open an issue in the library repository.",
|
||||
componentNameString,
|
||||
componentNameString,
|
||||
@"Legacy ViewManagers should be migrated to Fabric ComponentViews in the new architecture to reduce risk. Component using interop layer: %@",
|
||||
componentNameString]);
|
||||
|
||||
auto flavor = std::make_shared<const std::string>(name);
|
||||
|
||||
Reference in New Issue
Block a user