I'm building an Android app with Cordova 11. I have a QR code, which is something like: myapp://testapp?id=12345.
and in config.xml, i've set up the schema like this:
<action android:name="android.intent.action.VIEW" /> <category android:name="android.intent.category.DEFAULT" /> <category android:name="android.intent.category.BROWSABLE" /> <data android:scheme="myapp" />
and when I use camera to scan the QR code, and it open the app, but the handleOpenURL is not called, so I couldn't get the parameter - id from the URL.
Does someone have any ideas about the issue ? I've done a lot of search on internet, and chatgpt, but still can't get it working.
Thanks a lot!
I've tried put handleOpenURL in both resume and ondeviceready event.