1. /**
    
  2.  * Copyright (c) Meta Platforms, Inc. and affiliates.
    
  3.  *
    
  4.  * This source code is licensed under the MIT license found in the
    
  5.  * LICENSE file in the root directory of this source tree.
    
  6.  *
    
  7.  * @format
    
  8.  * @flow
    
  9.  */
    
  10. 
    
  11. 'use strict';
    
  12. 
    
  13. import {BatchedBridge} from 'react-native/Libraries/ReactPrivate/ReactNativePrivateInterface';
    
  14. 
    
  15. import type {ReactFabricType} from './ReactNativeTypes';
    
  16. 
    
  17. let ReactFabric;
    
  18. 
    
  19. if (__DEV__) {
    
  20.   ReactFabric = require('../implementations/ReactFabric-dev');
    
  21. } else {
    
  22.   ReactFabric = require('../implementations/ReactFabric-prod');
    
  23. }
    
  24. 
    
  25. global.RN$stopSurface = ReactFabric.stopSurface;
    
  26. 
    
  27. if (global.RN$Bridgeless !== true) {
    
  28.   BatchedBridge.registerCallableModule('ReactFabric', ReactFabric);
    
  29. }
    
  30. 
    
  31. module.exports = (ReactFabric: ReactFabricType);