1import { NativeModulesProxy } from 'expo-modules-core';
2import { NativeModule } from 'react-native';
3
4export default NativeModulesProxy.ExpoAppleAuthentication ||
5  // If the real native module doesn't exist, make a pretend one, instead of
6  // `null`, so we can offer an `isAvailableAsync` (that will always give
7  // `false`, because we're on an unsupported platform).
8  ({
9    isAvailableAsync(): Promise<boolean> {
10      return Promise.resolve(false);
11    },
12
13    // RN v0.65 gives a console warning if this method is missing; see
14    //   https://github.com/facebook/react-native/commit/114be1d21
15    addListener() {
16      // Nothing to do; unsupported platform.
17      return Promise.resolve();
18    },
19
20    // RN v0.65 gives a console warning if this method is missing; see
21    //   https://github.com/facebook/react-native/commit/114be1d21
22    removeListeners() {
23      // Nothing to do; unsupported platform.
24      return Promise.resolve();
25    },
26  } as NativeModule);
27