1import type { NavigationContainerRef } from '@react-navigation/core';
2import type { LinkingOptions } from '@react-navigation/native';
3
4declare let global: {
5  __DEV__?: boolean;
6  RN$Bridgeless?: boolean;
7  __METRO_GLOBAL_PREFIX__?: string;
8  __RCTProfileIsProfiling?: boolean;
9  WebSocket: any;
10  REACT_NAVIGATION_DEVTOOLS: WeakMap<
11    NavigationContainerRef<any>,
12    { readonly linking: LinkingOptions<any> }
13  >;
14};
15
16// Only during development.
17if (process.env.NODE_ENV !== 'production') {
18  if (
19    // Disable for SSR
20    typeof window !== 'undefined' &&
21    // Disable for non-metro runtimes
22    // NOTE(EvanBacon): This can probably be removed in favor of `expo/metro-config` injecting this file.
23    global.__METRO_GLOBAL_PREFIX__ != null
24  ) {
25    require('./setupFastRefresh');
26    require('./setupHMR');
27    require('./messageSocket');
28  }
29}
30