UNPKG

react-native-my-app-list

Version:

Get user-facing installed apps for React Native Android using privacy-friendly queries instead of QUERY_ALL_PACKAGES permission.

15 lines (14 loc) 431 B
"use strict"; import { Platform } from 'react-native'; import MyAppList from "./NativeMyAppList.js"; export const getInstalledApps = async () => { if (Platform.OS !== 'android') { throw new Error('This feature is only available on Android'); } try { return await MyAppList.getInstalledApps(); } catch (error) { throw new Error(`Failed to get installed apps: ${error}`); } }; //# sourceMappingURL=index.js.map