EddyVerbruggen / nativescript-plugin-firebase

:fire: NativeScript plugin for Firebase
https://firebase.google.com
MIT License
1.01k stars 446 forks source link

iOS not showing notification popup ( All Steps Followed ) #1590

Closed MohammedBashiru closed 4 years ago

MohammedBashiru commented 4 years ago

Hello @EddyVerbruggen.

I have followed every steps. I tested on both Simulator and Real Device.

I have created certifacte and uploaded to fire base console. I have enabled notification in entitlements. I do receive token addOnMessageReceivedCallback works well. I get message data.

But popup won't show.

What could I be missing possibly for the notification popup not to show.

tns = 6.5.0 "tns-android": { "version": "6.5.0" }, "tns-ios": { "version": "6.5.0" }

manojdcoder commented 4 years ago
  1. Background (APNS) notifications will not work on Simulator
  2. If you are running debug build, make sure you uploaded debug certificate & your APS environment is set to development.
  3. If you want to see notification while app is on foreground, ensure you have set showNotificationsWhenInForeground to true

If you still have issues, please share a sample project.

lorenzk commented 4 years ago

Sidebar: since xcode 11.4, there ways to test notifications in simulator. I created JSON files and dragged them onto my simulator, following this tutorial: Testing push notifications on the iOS simulator

MohammedBashiru commented 4 years ago

Trust me I had not configuration error. I woke up this morning only to see the notifications work. Its the same configuration as I tested on friday and it wasn't working.

Am assuming it takes time for Apple APNS Certificate to register for FCM to work with it.

@manojdcoder Yes earlier I tested both on Real device and similar. I added my real device to my development account.

Its all working now. But I'd like anyone who just installed this plugin after configuring the Apple development account under 24 hours should wait for sometime if the notification is not working ( and you are sure you have followed all necessary steps as I did lol ).