Repository navigation
Replies: 1 comment
|
Hi @sapooler, Thanks for opening this discussion and for taking the time to suggest this improvement. You were right that the Android side was not very discoverable compared to the iOS NotifyKit already supports Android notification numbers through await notifee.createChannel({
id: 'messages',
name: 'Messages',
badge: true,
});
await notifee.displayNotification({
id: 'messages',
title: 'New messages',
body: 'You have 5 unread messages',
android: {
channelId: 'messages',
badgeCount: 5,
},
});
If you want to update that number, you can display the notification again using the same notification There is, however, an important difference compared with iOS. On iOS, On Android, The actual visual result is launcher/OEM dependent:
On Android 8.0+ the notification channel must also allow badging, for example with So the functionality you suggested is already available, but the documentation did not make it clear enough. We have now updated both the README and the Android badges documentation to explain Thanks again for bringing this up. Your suggestion helped us identify a real documentation/discoverability gap and make the existing Android functionality much easier to find. |
Uh oh!
There was an error while loading. Please reload this page.
Is there a reason why there's no android equivalent to the setBadgeCount function available in the build on iOS?
I noted that under the hood in Kotlin you can do something like
which should set the notification number in the badge on newer versions of android.
Hence I was wondering if something similar is on the way?
All reactions