简体   繁体   English

React Native Schedule 本地通知最佳实践

[英]React Native Schedule Local Notification Best Practices

I'm building an app with React Native and handling local notifications with https://github.com/zo0r/react-native-push-notification我正在使用 React Native 构建应用程序并使用https://github.com/zo0r/react-native-push-notification处理本地通知

The problem is, When I research about scheduling local notifications, I believe there is a limit for that.问题是,当我研究安排本地通知时,我相信这是有限制的。 My applications purpose is about sending notifications so I need to send 10-15 of them in a day.我的应用程序目的是发送通知,所以我需要在一天内发送 10-15 个。 What is the best practice for that with React Native? React Native 的最佳实践是什么?

Should I somehow schedule some events for scheduling local notifications or should I use some remote push notifications?我应该以某种方式安排一些事件来安排本地通知,还是应该使用一些远程推送通知?

There's no limit on scheduling local notifications.安排本地通知没有限制。 I'm not sure there is limit or not but you can send 10-15 of notifications in a day using this library because I'm using it in that way.我不确定是否有限制,但您可以使用这个库在一天内发送 10-15 条通知,因为我正在以这种方式使用它。

Important thing is that you should set each notification's id (in case of ios userInfo ) and it should be different each other.重要的是您应该设置每个通知的id (在 ios userInfo的情况下)并且它应该彼此不同。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM