-
Notifications
You must be signed in to change notification settings - Fork 766
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Handle callback when notification in background / terminate app #1037
Comments
Same here , Please provide the fix |
I am observing the following:
This is on I have set I also ensured that |
Just to bump this: this bug appears to be related to a lack of push notifications on Android API 33 and above, when the app is in the background. If anyone has any ideas I am happy to debug further! |
Same problem here in iOS. registerNotificationReceivedBackground does not log. |
Any update on this ? |
Hi! I have the same problem on android, but I found that if send message with only field "data"(without "notification" field) I can handle callback when app in background, but if app terminate it not worked! If exist "notofication" field, I can't handle in background and terminate mode.
Any solutions? PS If I override FcmService on native, I can handle all message on all modes in onMessage method but then Notifications.events().. can't work. PS2 I understood the problem. It's can't work when app terminated because rn-notification need React Context but if app terminated ReactContext is null and then method on JS can't fire from native code. |
How to handle callback when Notificationin background?
I have put the code into
index.js
The
Notifications.events().registerNotificationReceivedForeground
cllback in working well.when I using
Notifications.events().registerNotificationReceivedBackground
the notif is successful to show in background / terminate, but I cannot getting any callback in my log.Please help
The text was updated successfully, but these errors were encountered: