I've been doing a few searches on google trying to find a way to run foreground services in react native but I haven't found much about it.
Is anyone aware of how to accomplish this? This is what I mean by foreground service: https://developer.android.com/guide/components/services.html#Foreground
I have an example React Native Foreground Service app here. In this example, I'm doing a Bluetooth scan every 10 seconds and attempting to run a Foreground Service so that the scans will continue even if the app isn't in the foreground.
You can remove the call in
index.jsthat does the BLE scan and you'll have a simple RN Foreground Service example.