0

I am struggling with PWA and badging. I added if (navigator.setAppBadge) { navigator.setAppBadge(6); } to the push notification method(service-worker.js) and it works fine on windows(chrome browser) but it doesn't work on android(also chrome browser). Consent to notifications granted. Are you able to advise what is wrong or what I miss or maybe android requires additional permissions?

Thanks in advance.

I tried set badge without number but it also don't work. I also check if I can add additional permission for PWA app on the Android device.

  • perhaps, as you surmised, you need [permission](https://w3c.github.io/badging/#example-checking-for-permission) – Jaromanda X Jul 14 '23 at 08:44
  • permission is granted, I can send push notification to the mobile device – Adam Stroka Jul 14 '23 at 10:07
  • Please clarify your specific problem or provide additional details to highlight exactly what you need. As it's currently written, it's hard to tell exactly what you're asking. – Community Jul 14 '23 at 11:26
  • The badge does not appear on the icon of the installed PWA app on Android. It works fine on Windows. – Adam Stroka Jul 14 '23 at 13:45

0 Answers0