Skip to content

Commit

Permalink
delete concurrentRoot option from ReactFabric.render
Browse files Browse the repository at this point in the history
  • Loading branch information
sammy-SC committed Nov 11, 2024
1 parent ed15d50 commit 0a3f8d7
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions packages/react-native-renderer/src/ReactFabric.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,6 @@ import {getPublicInstanceFromInternalInstanceHandle} from './ReactFiberConfigFab

// Module provided by RN:
import {ReactFiberErrorDialog} from 'react-native/Libraries/ReactPrivate/ReactNativePrivateInterface';
import {disableLegacyMode} from 'shared/ReactFeatureFlags';

if (typeof ReactFiberErrorDialog.showErrorDialog !== 'function') {
throw new Error(
Expand Down Expand Up @@ -100,13 +99,8 @@ function render(
element: Element<ElementType>,
containerTag: number,
callback: ?() => void,
concurrentRoot: ?boolean,
options: ?RenderRootOptions,
): ?ElementRef<ElementType> {
if (disableLegacyMode && !concurrentRoot) {
throw new Error('render: Unsupported Legacy Mode API.');
}

let root = roots.get(containerTag);

if (!root) {
Expand All @@ -131,7 +125,7 @@ function render(
// We could create a wrapper for containerTag as well to reduce special casing.
root = createContainer(
containerTag,
concurrentRoot ? ConcurrentRoot : LegacyRoot,
ConcurrentRoot,
null,
false,
null,
Expand Down

0 comments on commit 0a3f8d7

Please sign in to comment.