DEV Community

Discussion on: Basics and caveats of Expo-notifications

Collapse
 
joaquinbian profile image
joaquinbian • Edited

Nice post! I have one question, if I have to send a notification like a reminder of an event, in a specific date, should I use local-notifications? And there is a way to send notifications when the app is killed?

Collapse
 
marianapatcosta profile image
Mariana Costa

Thank you for your comment.
Yes, the local notifications should be used for reminders. And yes, we can receive notifications when the app is killed but, as far as I know, there is no way to react to it, I mean there is no way add a listener and execute some code when a notification is received when the app is killed. Thus, we can receive and read a message, but we cannot increase the badge count when we receive a notification when the app is killed, for example.

Collapse
 
joaquinbian profile image
joaquinbian

Nice! Thanks for the answer! And I can i send these notifications event if they are local-notifications? Or I can receive only notifications from a server when app is killed?

Collapse
 
marianapatcosta profile image
Mariana Costa

Unfortunately, I did not test that but considering that the app triggers a local notification to display in the device when a push notification is received, I believe the behaviour is the same. Thus, we probably can still receive a local notification when the app is killed but we cannot react to it.