This module allows you to listen for scan events emitted by Honeywell NXXX scanners on Android devices.
From npm
$ npm install --save react-native-scan-device
From GitHub
$ npm install --save git+https://github.com/mediaburg/react-native-scan-device
Linking is done automatically in react-native 0.60+
cli-linking (only < 0.60)
$ react-native link react-native-scan-device
import ScanDevice from 'react-native-scan-device';
// Create a receiver
const receiver = ScanDevice.onReceive((e) => {
console.log(`Scanned Value: ${e.data}`);
});
// Remove the receiver
receiver.remove();
// Programmatically start scanning
ScanDevice.startScan();
// Programmatically stop the scanner (only needed if continuous scanning is active, which is not currently implemented)
ScanDevice.stopScan();