This is an experimental technology
Check the Browser compatibility table carefully before using this in production.
The badge
property of the Notification
interface returns the URL of the image used to represent the notification when there is not enough space to display the notification itself.
var url = Notification.badge
A USVString
containing a URL.
Specification | Status | Comment |
---|---|---|
Notifications API The definition of 'badge' in that specification. | Living Standard | Initial definition. |
Feature | Chrome | Firefox (Gecko) | Internet Explorer | Opera | Safari |
---|---|---|---|---|---|
Basic support | 53 | No support | No support | 39 | No support |
Available in workers | 53 | No support | No support | 39 | No support |
Secure contexts only | 62 | No support | No support | 49 | No support |
Feature | Android Webview | Chrome for Android | Firefox Mobile (Gecko) | Firefox OS | IE Mobile | Opera Mobile | Safari Mobile |
---|---|---|---|---|---|---|---|
Basic support | No support | 53 | No support | No support | No support | 39 | No support |
Available in workers | No support | 53 | No support | No support | No support | 39 | No support |
Secure contexts only | No support | 62 | No support | No support | No support | 49 | No support |
© 2005–2018 Mozilla Developer Network and individual contributors.
Licensed under the Creative Commons Attribution-ShareAlike License v2.5 or later.
https://developer.mozilla.org/en-US/docs/Web/API/Notification/badge