Skip to content

A cordova plugin to determine whether the app was installed from the Google Play Store (Android)

License

Notifications You must be signed in to change notification settings

servicesoftuk/cordova-plugin-app-store-check

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Cordova AppStoreCheck plugin

A plugin to determine whether or not the app was installed via an app store. Currently only works for Android and the Google play store but may be expanded in future to include iOS.

Installation

With cordova-cli

If you are using cordova-cli, install with:

cordova plugin add cordova-plugin-app-store-check

Use from Javascript

If you are using jQuery, AngularJS, WinJS or any Promise/A library (Bluebird), promise style is supported. Use something like:

    cordova.plugins.appstorecheck.isInstalledFromAppStore().then(function (installedFromAppStore) {
        alert(installedFromAppStore);
    });

If not, pass a callback function:

cordova.plugins.appstorecheck.isInstalledFromAppStore(function(installedFromAppStore) {
  alert(installedFromAppStore);
});

Output

isInstalledFromAppStore() returns 1 if the app was installed from the google play store, otherwise 0.

About

A cordova plugin to determine whether the app was installed from the Google Play Store (Android)

Resources

License

Stars

Watchers

Forks

Packages

No packages published