You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is it possible to make onNotification listener to run every time my app receives a remote notification?
Currently this behaviour is the behaviour for each app state:
Foreground
iOS: onNotification is called (this is working after changing AppDelegate.mm)
Android: onNotification is triggered
Background
iOS: onNotification is not called
Android: N/A
Killed/Closed
iOS: onNotification is not called
Android: N/A
So, I wanted that onNotification would be called for every remote notification received, doesn't matter the app state. After reading some issues in the repository and some posts on stack overflow, it seems to be possible, but I'm not sure.
If anyone have some idea how to achieve this, please let me know.
My goal is to receive remote notifications, but never show remote notifications to the user, and once onNotification is called, send a localNotification instead.
The text was updated successfully, but these errors were encountered:
the reason you are not receiving notification in background or killed is because you are doing the pushNotification.configure after the AppRegistry.registerComponent(appName,()=>App) (ie in App.js). If you do it in index.js, you should receive the notification in all states. It works for me...
Question
Is it possible to make
onNotification
listener to run every time my app receives a remote notification?Currently this behaviour is the behaviour for each app state:
Foreground
Background
Killed/Closed
So, I wanted that onNotification would be called for every remote notification received, doesn't matter the app state. After reading some issues in the repository and some posts on stack overflow, it seems to be possible, but I'm not sure.
If anyone have some idea how to achieve this, please let me know.
My goal is to receive remote notifications, but never show remote notifications to the user, and once onNotification is called, send a localNotification instead.
The text was updated successfully, but these errors were encountered: