4

What is the most stable and functionality-rich FCM plugin for Cordova. All that is needed is receiving push messages and a FCM registration token. Both foreground and background.

I have tried https://github.com/fechanique/cordova-plugin-fcm and it does the job for Android but not for iOS as I don't get the js callback. So I am looking for an alternative that would work the SAME on both platforms.

Thanks in advance for answering

AL.
  • 36,815
  • 10
  • 142
  • 281
Robert K.
  • 1,043
  • 1
  • 8
  • 20

3 Answers3

9

Well, in my knowledge, there is no better plugin for FCM. Either you try to debug this plugin, or use one of these two (I never tested them):

https://www.npmjs.com/package/cordova-plugin-firebase

https://www.npmjs.com/package/cordova-plugin-fcm-afronutt

Please comment on this if one of them work for you, so that you benefit the others.

[EDIT] Apparently, the second link is just the same plugin that you use.

[EDIT2] See This for a possible solution of your problem with cordova-plugin-fcm

[EDIT3] I use cordova-plugin-fcm for both IOS and Android till today 18/6/2018. It works perfectly fine. I update IOS on my IPhone 5 frequently. So it is up-to-date.

AhmadWabbi
  • 2,253
  • 1
  • 20
  • 35
3

I worked on a fork of cordova-plugin-firebase - npm to provide FCM notification service on my app in addition to phone number verification. I also tested it on Android and iOS. You can find my fork at GitHub.

Ahmed Wahba
  • 96
  • 1
  • 7
2

If I understand your question correctly, you want to be able to use push notifications (and the registration token is for that).

I haven't used it myself (yet) but phonegap push plugin recently (see announcement from August) moved to work through FCM.

The old plugin used to work with GCM and now they migrated it to work with FCM. It supports both Android and iOS and still, if you want, let you use APNS as older plugins used to do.

The project seems to be better documented, with lots of example payloads, detailed options and nuances of each device etc, and is very active (108/1544 watches/stars vs. 58/418, on 2017-11-04) with latest update a few days ago (vs. 5/6 month for cordova-plugin-fcm).

From my impression, phonegap-plugin-push is more widely used...

With that being said, I don't have concrete experience with either - only with the predecessor of phonegap-plugin-push.

Tomer Cagan
  • 1,078
  • 17
  • 31