Ionic React QR scanner

hey,

im trying to use the capacitor QR scanner on ionic 6 react. It works fine on Android, but not on iOs (at least on an iOs emulator it doesn’t work). Anyone managed this?

import { BarcodeScanner } from ‘@ionic-native/barcode-scanner’;

const scanCode = async () => {
const data = await BarcodeScanner.scan();
};

In iOs it just hangs/nothing happens and the console says -
" To Native Cordova -> BarcodeScanner scan BarcodeScanner102680008 [“options”: []]"

Not very useful

1 Like

I never tried that plugin, but the iOS Simulator doesn’t support the camera so I don’t see how you can scan anything there.

yup, cheers. after spending a couple of hours i found that out. sigh.

1 Like

Hello, did you have any problem with ionic cordova plugin
phonegap-plugin-barcodescanner in Android Studio?

I think it is not compatible with React … I have that problem