jamesisaac / react-native-background-task

Periodic background tasks for React Native apps, cross-platform (iOS and Android), which run even when the app is closed.
MIT License
1.1k stars 110 forks source link

Tasks that occur every 30 seconds #18

Closed gusilveiramp closed 6 years ago

gusilveiramp commented 6 years ago

Hi @jamesisaac I'm working with background geolocation and need it to run a check every 30 seconds to check if the user is in a certain location and send a push. I set the "priod" to 60, but nothing happens when the app goes to background.

Is it possible to work this way with your library?

jamesisaac commented 6 years ago

Hi there,

Both iOS and Android enforce a minimum period of 15 minutes on the type of scheduling used by this library.

For your use case, I'd recommend something more purpose-built, like this: https://github.com/transistorsoft/react-native-background-geolocation