Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
814 views
in Technique[技术] by (71.8m points)

expo - React-native fetch data periodically and schedule local notifications

I need to set notifications daily multiple times. The timings data (which is variable) is being fetched by an API. For this I probably need a background task that will periodically fetch the data for the week/day. That task should obviously run even when the app is closed/terminated because rarely an app is in the foreground/background. But all the libraries/packages (e.g expo's TaskManager/BackgroundFetch, react-native-background-fetch, react-native-background-task etc) I have searched have some limitations e.g. they wouldn't work when an app is terminated (swiped away from the recent apps list) or they wouldn't work for IOS when an app is terminated

I need an all-rounder library that would:

  1. execute background task even when an app is closed
  2. work for android + ios

It is such a common use case but I am unable to find any solution

question from:https://stackoverflow.com/questions/65913365/react-native-fetch-data-periodically-and-schedule-local-notifications

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)
Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...