How to use the nativescript-barcodescanner.hasCameraPermission function in nativescript-barcodescanner

To help you get started, we’ve selected a few nativescript-barcodescanner examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github EddyVerbruggen / nativescript-barcodescanner / demo / main-view-model.js View on Github external
DemoAppModel.prototype.doCheckHasCameraPermission = function () {
    barcodescanner.hasCameraPermission().then(
        function(granted) {
          dialogs.alert({
            title: "Permission granted?",
            message: granted ? "YES" : "NO",
            okButtonText: "OK"
          })
        }
    )
  };