Skip to content

Commit

Permalink
Enable Bridgeless
Browse files Browse the repository at this point in the history
Summary: Set RuntimeConfig for RNTester

Reviewed By: cortinico

Differential Revision: D46527569

fbshipit-source-id: f0fe0a169723390585e9eeb672cb799953f57e85
  • Loading branch information
Lulu Wu authored and facebook-github-bot committed Jun 24, 2023
1 parent 0876170 commit f1d8214
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions packages/rn-tester/js/RNTesterAppShared.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,15 @@ import {BackHandler, StyleSheet, View, useColorScheme} from 'react-native';

// RNTester App currently uses in memory storage for storing navigation state

if (global.RN$Bridgeless) {
require('react-native/Libraries/NativeComponent/NativeComponentRegistry').setRuntimeConfigProvider(
name => {
// In bridgeless mode, never load native ViewConfig.
return {native: false, strict: false, verify: false};
},
);
}

const RNTesterApp = (): React.Node => {
const [state, dispatch] = React.useReducer(
RNTesterNavigationReducer,
Expand Down

0 comments on commit f1d8214

Please sign in to comment.