react-native-push-notification icon indicating copy to clipboard operation
react-native-push-notification copied to clipboard

onNotification is not called when send message from FCM at backgroud

Open hoangpm2 opened this issue 8 years ago • 6 comments

Hi, I put console.log(notification) in function onNotification(). When i send a message from fcm in foreground, it works fine. But in background, i dont see any log of notification. I tried with GCM but GCM work well, and FCM is error like that. Did i miss something in file AndroidManifest.mxl ? Please help me. Thank you so much.

hoangpm2 avatar Nov 26 '18 12:11 hoangpm2

Facing the same issue. To me it feels like the app gets re-opened when I receive FCM notification while being in background.

gontovnik avatar Nov 27 '18 23:11 gontovnik

Did you figure this out? Can you confirm that this library allows you to receive remote push notifications while the app is closed, and also show an alert to the user? Thanks.

cristianocca avatar Dec 14 '18 02:12 cristianocca

Oh sorry i forgot this. After 3 days try to find a solutions and can not find anything, and because i have to config notification for my project, i decided to use another library. It is react-native-firebase. That library has a specific event when you click to notification in background. I think this react-native-push-notification miss that event.

hoangpm2812 avatar Dec 14 '18 03:12 hoangpm2812

Facing the same issue. To me it feels like the app gets re-opened when I receive FCM notification while being in background.

Facing the same problem. Anyone found a solution for this yet?

rashidul-hasan avatar Feb 05 '19 06:02 rashidul-hasan

@hoangpm2 sir, just want to ask on how did you configure it using react-native-firebase?

Ethan0007 avatar May 02 '19 08:05 Ethan0007

This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 30 days if no further activity occurs. Thank you for your contributions.

github-actions[bot] avatar May 22 '20 00:05 github-actions[bot]