diff --git a/README.md b/README.md index baf2a4ff..03a9cf8f 100644 --- a/README.md +++ b/README.md @@ -42,26 +42,13 @@ Note: Windows 10 applications can not be build for `AnyCPU` architecture, which cordova run windows -- --archs=x86 ``` -Note: Since iOS 10 it's mandatory to add a `NSCameraUsageDescription` in the info.plist. - -`NSCameraUsageDescription` describes the reason that the app accesses the user’s camera. -When the system prompts the user to allow access, this string is displayed as part of the dialog box. - -To add this entry you can pass the following variable on plugin install. - -``` -cordova plugin add phonegap-plugin-barcodescanner --variable CAMERA_USAGE_DESCRIPTION="To scan barcodes" -``` - ### PhoneGap Build Usage Add the following to your config.xml: ``` - - - + ``` On PhoneGap Build if you're using a version of cordova-android of 4 or less, ensure you're building with gradle: ``` @@ -144,6 +131,21 @@ A full example could be: ); ``` +## iOS quirks ## + +Since iOS 10 it's mandatory to add a `NSCameraUsageDescription` in the `Info.plist`. + +`NSCameraUsageDescription` describes the reason that the app accesses the user's camera. +When the system prompts the user to allow access, this string is displayed as part of the dialog box. If you didn't provide the usage description, the app will crash before showing the dialog. Also, Apple will reject apps that access private data but don't provide an usage description. + +To add this entry you can use the `edit-config` tag in the `config.xml` like this: + +``` + + To scan barcodes + +``` + ## Windows quirks ## * Windows implementation currently doesn't support encode functionality. diff --git a/plugin.xml b/plugin.xml index 686cc9b4..105af0ff 100644 --- a/plugin.xml +++ b/plugin.xml @@ -18,10 +18,6 @@ - - $CAMERA_USAGE_DESCRIPTION - -