mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
Warn when fabric is used without concurrent root (#41072)
Summary: Pull Request resolved: https://github.com/facebook/react-native/pull/41072 As part of the new architecture rollout, we want to simplify our set of supported configurations. Right now it is possible to use Fabric / new architecture without using concurrent root, which prevents us from bringing the new concurrent capabilities to these applications and holds back React renderer code. Changelog: [Deprecated] Using the new architecture without concurrent root will soon not be supported. Reviewed By: rubennorte, sammy-SC Differential Revision: D50425540 fbshipit-source-id: 1ec4c8202074e6ea98178f1a07311fda35b1951b
This commit is contained in:
committed by
Facebook GitHub Bot
parent
0b8fd748ee
commit
c06807154b
@@ -22,7 +22,6 @@ const reactDevToolsHook = window.__REACT_DEVTOOLS_GLOBAL_HOOK__;
|
||||
type Props = $ReadOnly<{|
|
||||
children?: React.Node,
|
||||
fabric?: boolean,
|
||||
useConcurrentRoot?: boolean,
|
||||
rootTag: number | RootTag,
|
||||
initialProps?: {...},
|
||||
showArchitectureIndicator?: boolean,
|
||||
|
||||
@@ -83,6 +83,12 @@ export default function renderApplication<Props: Object>(
|
||||
);
|
||||
}
|
||||
|
||||
if (fabric && !useConcurrentRoot) {
|
||||
console.warn(
|
||||
'Using Fabric without concurrent root is deprecated. Please enable concurrent root for this application.',
|
||||
);
|
||||
}
|
||||
|
||||
performanceLogger.startTimespan('renderApplication_React_render');
|
||||
performanceLogger.setExtra(
|
||||
'usedReactConcurrentRoot',
|
||||
|
||||
Reference in New Issue
Block a user