iOS : notifications works only after installing app
See original GitHub issueOn iOS, I can make work the notifications (cloud messaging) only after the app installation Also it only works for foreground notifications (background notifs are all received at resuming app)
But if I kill the app, or if the app close by itself (after long pausing), or after the next tns run ios
, then the notifications stop to work at all :
- onMessageReceivedCallback (inside init option) is ever no more called
- firebase.addOnMessageReceivedCallback no more called too Until the next installation…
I use firebase console to send notifications, and whether I use single device (FCM) or user segment as target, the result is the same : it works only after the app installation
Here is version I use :
- iPhone 6 (version 10.2 (14C92)
- nativescript plugin firebase : 3.11.4
- tns info :
- angular : 2.4.3
- nativescript : 2.5.4 │ Up to date
- tns-core-modules : 2.5.2 │ Up to date
- tns-android : 2.5.0 │ Up to date
- tns-ios : 2.5.0 │ Up to date
On android, it works great
Issue Analytics
- State:
- Created 6 years ago
- Reactions:1
- Comments:12
Top Results From Across the Web
Notifications only show when I launch the app
I'm using iPhone 11 Pro Max and only recently I've experience this issue where none of my notification is alerting me unless I...
Read more >Push notification works only when app launched with Xcode
Everything works perfectly, only when I launch my application without the help of Xcode, I no longer receive the notifications, the ...
Read more >Notifications not working in iOS 16? 9 Ways to fix it! - iGeeksBlog
To fix Notifications not working on iPhone running iOS 16, 1. Turn off Focus on iPhone, 2. Add exceptions to Focus, 3.
Read more >Top 8 Tips to Fix iPhone Notifications Not Working on iOS 16/15
Press and hold the icon of the app you're not receiving notification from until all of the icons on the screen start to...
Read more >Notifications Not Shown - Mobile Push
Step 2: Settings --> Apps or Notification Manager --> Advanced or Notify for your app --> Ignore Battery Optimizations, select the app and...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Had this same issue for several days on iOS. (Tested on both iOS 9 and iOS 10), {N} 3
Running firebase.init before the application has launched seems to be the cause of the issue. This can be remedied by running firebase.init in your first view-model.
Hope this helps.
These tips should be documented, particularly this: https://github.com/EddyVerbruggen/nativescript-plugin-firebase/issues/359#issuecomment-303953577