Closed kvowinckel closed 4 years ago
Capacitor uses APNS for push notifications on iOS and they work fine, if you are using FCM then you probably did something wrong, sorry, I can't help you with that.
Thanks for the issue! This issue is being locked to prevent comments that are not relevant to the original issue. If this is still an issue with the latest version of Capacitor, please create a new issue and ensure the template is fully filled out.
What works:
I can send push notifications via FCM to my ionic app, as long as the message has next to data a notification as well. Both, on iOS and Android, the os notification is displayed when the app is in background. And in both, I can also work with the registered listener within the app to perform actions.
Server-side:
App-side:
What does not work:
Now I also want to send a notification to the app, which is silently when the app is in the background, but triggers the registered listener, when the app is in foreground. Therefore, I am sending a data message via FCM (nit containing a notification). While this works in the Android App, nothing arrives in the iOS app.
I also tried to add
without success.
Installed Dependencies:
@capacitor/electron not installed
@capacitor/cli 2.0.0
@capacitor/core 2.0.0
@capacitor/ios 2.0.0
@capacitor/android 2.0.0
XCode: iOS: 11.0
Ionic:
Ionic CLI : 6.7.0 Ionic Framework : @ionic/angular 5.0.7 @angular-devkit/build-angular : 0.803.26 @angular-devkit/schematics : 8.3.26 @angular/cli : 8.3.26 @ionic/angular-toolkit : 2.2.0
Capacitor:
Capacitor CLI : 2.0.0 @capacitor/core : 2.0.0