Installation
To install the Scanbot Barcode Scanner SDK module you can run the following in your root project folder
- Yarn
- npm
- Expo
yarn add react-native-scanbot-barcode-scanner-sdk
npm install react-native-scanbot-barcode-scanner-sdk
npx expo install react-native-scanbot-barcode-scanner-sdk
Expo
Integration with Expo is possible only when using a development build. The project is configurable using our config plugin or manually configure the native projects. To utilize the plugin you can add the following in your app config file:
"plugins": [
[
"react-native-scanbot-barcode-scanner-sdk",
{
"iOSCameraUsageDescription": "Barcode Camera permissions",
"androidCameraPermission": true,
"androidCameraFeature": true,
"mavenURLs": true
}
]
],
iOSCameraUsageDescription
: AddsNSCameraUsageDescription
in Info.plist. The permission can also be added via Expo PermissionsandroidCameraPermission
: Addsandroid.permission.CAMERA
permission in AndroidManifest.xml. The permission can also be added via Expo PermissionsandroidCameraFeature
: Addsandroid.hardware.camera
feature in AndroidManifest.xmlmavenURLs
: Adds Scanbot Barcode Scanner SDK Maven urls for Android local development. These URLs are already included in our package's build.gradle, but need to be added due to how Expo starts the Android app.
Want to scan longer than one minute?
Generate a free trial license to test the Scanbot SDK thoroughly.
Get your free Trial LicenseWhat do you think of this documentation?
What can we do to improve it? Please be as detailed as you like.