UNPKG

react-native-simple-version-update

Version:

react-native-simple-version-update is a lightweight and easy-to-use custom React Native hook that checks if your app needs to be updated by comparing the installed version with the latest version available on the App Store (iOS) or Google Play Store (Andr

19 lines (18 loc) 675 B
export interface UseVersionUpdateReturn { currentVersion: string | null; liveVersion: string | null; needUpdate: boolean; isLoading: boolean; error: Error | null; handleUpdate: () => Promise<void>; checkForUpdate: () => Promise<void>; } /** * Custom React Native hook to check if your app needs to be updated * by comparing the installed version with the latest version available * on the App Store (iOS) or Google Play Store (Android). * * @returns {UseVersionUpdateReturn} Object containing version info, update status, and helper functions */ declare const useVersionUpdate: () => UseVersionUpdateReturn; export default useVersionUpdate;