Ionic iOS应用程序在移至后台时,Signal-R事件不会更新(实时)吗?

huangapple go评论66阅读模式
英文:

Ionic IOS app's Signal-R events are not updating (realtime) when the app moved to background?

问题

我正在开发基于短信的Ionic IOS应用。我们正在使用Signal-R事件来实时更新应用程序。在Android上,当应用程序打开时,甚至在后台时,应用程序会实时更新。但在IOS应用中,当应用程序在后台运行时,它不起作用。 (这是一个电容器离子应用)

可能是什么问题?

英文:

I'm developing an sms based Ionic IOS app. And we are using Signal-R events to update the app in real-time. In Android, the app is updating real-time when it's opened and even in the background. But in the IOS app, it's not working when the app is in the background.
(This is a capacitor ionic app)

What may be the issue?

答案1

得分: 2

你需要使用 Capacitor 后台任务插件。此外,确保阅读指南。Apple 目前允许在应用关闭后最多运行 30 秒的后台任务,因此时间很有限。

英文:

You need to use the Capacitor background task plugin. Also make sure to read the guidelines. Apple currently allows a maximum of 30 seconds after an app has closed to run any bg task, so you have minimal time.

huangapple
  • 本文由 发表于 2023年4月4日 13:39:02
  • 转载请务必保留本文链接:https://go.coder-hub.com/75925820.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定