# QRCode scanner for Cordova under Angular 12

**URL:** <https://forum.ionicframework.com/t/qrcode-scanner-for-cordova-under-angular-12/213687>\
**Category:** Ionic Framework\
**Created:** [August 12, 2021, 6:05am UTC](https://forum.ionicframework.com/t/qrcode-scanner-for-cordova-under-angular-12/213687 "2021-08-12T06:05:53Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![iondafi](https://avatars.discourse-cdn.com/v4/letter/i/4da419/32.png) [@iondafi](https://forum.ionicframework.com/u/iondafi)\
**Post date:** [August 12, 2021, 6:05am UTC](https://forum.ionicframework.com/t/qrcode-scanner-for-cordova-under-angular-12/213687/1 "2021-08-12T06:05:53Z")

</div>

My Ionic 5 project uses Angular 12 and Cordova, now I need to scan QR-Codes (for covid green pass)

I tried [GitHub - zxing-js/ngx-scanner: Angular (2+) QR code, Barcode, DataMatrix, scanner component using ZXin](https://github.com/zxing-js/ngx-scanner) but doesn’t install with Angular 12  
I tried [GitHub - bitpay/cordova-plugin-qrscanner: A fast, energy efficient, highly-configurable QR code scanne](https://github.com/bitpay/cordova-plugin-qrscanner) but it doesn’t work well on Android 11 and latest iOS versions

All blog posts found are outdated or simply no longer valid for new version of Android

I can’t downgrade to other Angular versions

Any hints?

---

<div class="post-metadata">

**Author:** ![Tommertom](https://avatars.discourse-cdn.com/v4/letter/t/ed8c4c/32.png) [@Tommertom](https://forum.ionicframework.com/u/Tommertom)\
**Post date:** [August 12, 2021, 6:09am UTC](https://forum.ionicframework.com/t/qrcode-scanner-for-cordova-under-angular-12/213687/2 "2021-08-12T06:09:13Z")

</div>

Capacitor an option for you?

There are also js based scanners

---

<div class="post-metadata">

**Author:** ![iondafi](https://avatars.discourse-cdn.com/v4/letter/i/4da419/32.png) [@iondafi](https://forum.ionicframework.com/u/iondafi)\
**Post date:** [August 12, 2021, 7:44am UTC](https://forum.ionicframework.com/t/qrcode-scanner-for-cordova-under-angular-12/213687/3 "2021-08-12T07:44:32Z")

</div>

No, must be cordova

I can google to find js scanners but then I must test them under angular 12 + ionic 5, may you give me some name for components working well?

---

<div class="post-metadata">

**Author:** ![Tommertom](https://avatars.discourse-cdn.com/v4/letter/t/ed8c4c/32.png) [@Tommertom](https://forum.ionicframework.com/u/Tommertom)\
**Post date:** [August 12, 2021, 8:55am UTC](https://forum.ionicframework.com/t/qrcode-scanner-for-cordova-under-angular-12/213687/4 "2021-08-12T08:55:24Z")

</div>

I have taken the js implementation from the capacitor code

Fairly easy to adapt into any web project imho. And curated fairly recently

---

<div class="post-metadata">

**Author:** ![iondafi](https://avatars.discourse-cdn.com/v4/letter/i/4da419/32.png) [@iondafi](https://forum.ionicframework.com/u/iondafi)\
**Post date:** [August 12, 2021, 9:07am UTC](https://forum.ionicframework.com/t/qrcode-scanner-for-cordova-under-angular-12/213687/5 "2021-08-12T09:07:20Z")

</div>

I will try to dig on capacitor code, thanks

---

<div class="post-metadata">

**Author:** ![Tommertom](https://avatars.discourse-cdn.com/v4/letter/t/ed8c4c/32.png) [@Tommertom](https://forum.ionicframework.com/u/Tommertom)\
**Post date:** [August 12, 2021, 9:21am UTC](https://forum.ionicframework.com/t/qrcode-scanner-for-cordova-under-angular-12/213687/6 "2021-08-12T09:21:48Z")

</div>

Apologies, I cant find the code anymore and I am not behind my pc

Maybe try [How to Build a PWA QR Code Scanner with Ionic for iOS & Android | Devdactic - Ionic Tutorials](https://devdactic.com/pwa-qr-scanner-ionic/)?

---

<div class="post-metadata">

**Author:** ![Tommertom](https://avatars.discourse-cdn.com/v4/letter/t/ed8c4c/32.png) [@Tommertom](https://forum.ionicframework.com/u/Tommertom)\
**Post date:** [August 12, 2021, 9:26am UTC](https://forum.ionicframework.com/t/qrcode-scanner-for-cordova-under-angular-12/213687/7 "2021-08-12T09:26:19Z")

</div>

I remember again - I took the js code from the cordova plugin as published on ionic site

Here another example [ula-holder-workshop/scan-qr.page.ts at 39bad758893537850becb9f83b8e8f55115951b0 · Tommertom/ula-holder-workshop · GitHub](https://github.com/Tommertom/ula-holder-workshop/blob/39bad758893537850becb9f83b8e8f55115951b0/app/src/app/pages/scan-qr/scan-qr.page.ts)

(Not my code)

---

<div class="post-metadata">

**Author:** ![iondafi](https://avatars.discourse-cdn.com/v4/letter/i/4da419/32.png) [@iondafi](https://forum.ionicframework.com/u/iondafi)\
**Post date:** [August 13, 2021, 4:27am UTC](https://forum.ionicframework.com/t/qrcode-scanner-for-cordova-under-angular-12/213687/8 "2021-08-13T04:27:39Z")

</div>

Ok thanks, I will try to make something with this code

---

<div class="post-metadata">

**Author:** ![classhive](https://avatars.discourse-cdn.com/v4/letter/c/dc4da7/32.png) [@classhive](https://forum.ionicframework.com/u/classhive)\
**Post date:** [January 17, 2023, 4:37am UTC](https://forum.ionicframework.com/t/qrcode-scanner-for-cordova-under-angular-12/213687/9 "2023-01-17T04:37:54Z")

</div>

Hi, I noticed we have the same problem. Have you made the cordova-plugin-qrscanner work in Android 11? We’re currently facing the problem of not being able to scan the QRCode after migrating to Android 11 from Android 9.

---

<div class="post-metadata">

**Author:** ![rolinger](https://avatars.discourse-cdn.com/v4/letter/r/34f0e0/32.png) [@rolinger](https://forum.ionicframework.com/u/rolinger)\
**Post date:** [February 25, 2023, 2:29pm UTC](https://forum.ionicframework.com/t/qrcode-scanner-for-cordova-under-angular-12/213687/10 "2023-02-25T14:29:07Z")

</div>

@iondafi - any luck with this? I have run into the same issue with Cordova 11 on Android (cordova-android@11) and have not found a solution yet. Any alternatives? I have tried two different forks of the `cordova-plugin-qrscanner` and they too are failng. @classhive - any luck?
