Can we integrate FCM in cordova+ios and cordova+android ?
-
We’re only one step behind to refactor an old mobile app.
There is only one obscure point.
We need to be able to receive push notifications, obviously this must works even if app is not ‘opened’.Old posts pointed me to a cordova plugin, so I’m here to ask you for more updated info and some links / tutorials if available.
Thanks in advance
-
@realtebo - You might find someone here with experience on that subject, but the better source for an answer I would imagine would be in the Cordova community??
Scott
-
I will implement this next week. I will try to use this plugin: https://github.com/chemerisuk/cordova-plugin-firebase-messaging
If I have any advances, post here or sample code in github.
-
Thanks to both.
My question was more related to Quasar - Vue integration with FCM, because I already used cordova with FCM in the past.
What is not clear to me is how to receive events from the cordova plugin and then react inside the vue code. This requirement is because I don’t want only to see the notification, I need to pass it to the app to be stored as incoming message. -
@realtebo Lookin at this example, I built a boot called camera.js.
In it I configure cordova’s camera plugin (navigator.camera), and trigger one of its events.I wrapped it all up for a Promise, so I know if it worked or failed.
In quasar you can directly access the cordova plugins, in the vue itself. But as I will use it in many places, I have booted for a better organization.
Obs: cordova.plugins.diagnostic is a plugin I use to check permissions.