How to access camera in background using ionic capacitor/cordova on Android 9

509 Views Asked by At

I'm trying to get access to the camera while the app is in the background (e.g. the phone is locked). As it turns out, Android 9 does not allow to do that unless you are trying to get access using a foreground service. I'm using ionic framework in my application (camera is being accessed using navigator interface). Is there any way to run JS from the foreground service using native plugins or by any other means?

0

There are 0 best solutions below