Use Badging API if available to update the app badge
See original GitHub issueHi there, thanks for this extension, really cool!
Using the Badging API (spec, shipped to stable Chrome in April 2020), navigator.setAppBadge(notificationsCount)
and navigator.clearAppBadge()
can set and clear the application badge that shows up with PWA and pseudo-PWA windows (create a pseudo-PWA with three dots menu -> More Tools -> Create Shortcut… -> Open as window).
On macOS this looks like this in the Dock:
Issue Analytics
- State:
- Created 3 years ago
- Reactions:3
- Comments:5 (1 by maintainers)
Top Results From Across the Web
Badging for app icons - Chrome Developers
The App Badging API allows installed web apps to set an application-wide badge, shown in an operating-system-specific place associated with the application, ...
Read more >Badging API - MDN Web Docs - Mozilla
The Badging API gives web developers a method of setting a badge on a document or application, to act as a notification that...
Read more >How to create an app badge - web.dev
When the user installs the application, the badge is "upgraded" to a native ... If the app is installed and the Badging API...
Read more >Adding Notification Badges to Progressive Web Apps
Badges are a way of letting an app user know if there are actions or notifications waiting. The badging API brings native badges...
Read more >Re-engage users with badges, notifications, and push ...
Learn how to use the Push, Notifications, and Badging APIs to ... able to do work when the app isn't running, such as...
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 Free
Top 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
Sure, but you should send a feature request to GitHub too. This should ideally be implemented by them.
I’ve made the canvas favicon generator into a userscript here: https://github.com/karlhorky/dotfiles/blob/main/userscripts/github-favicon-notification-badge.user.js