import { NativeModules, Platform } from 'react-native'; const LINKING_ERROR = `The package 'tonelisten-react-native' doesn't seem to be linked.\n` + Platform.select({ ios: "\n- You have run 'pod install'\n", default: '' }) + '- You rebuilt the app after installing the package\n' + '- You are not using Expo Go (bare/Dev Client required)\n'; const Module = NativeModules.ToneListenReactNativeModule ? NativeModules.ToneListenReactNativeModule : new Proxy({}, { get() { throw new Error(LINKING_ERROR); } }); export const ToneListenNative = { openUrl: (url: string): Promise => Module.openUrl(url) }; // Export device ID service export { DeviceIdService } from './deviceId'; export type { DeviceInfo } from './deviceId';