-
-
Save davalapar/e536b49dd9c20851f5a014b0d8650d60 to your computer and use it in GitHub Desktop.
Notifications
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var n = new Notification('Connected', { body: 'Well done mate'} ); | |
setTimeout(() => n.close(), 3000); | |
Notification.permission; | |
Notification.requestPermission().then(console.log).catch(console.error); | |
// https://developer.mozilla.org/en-US/docs/Web/API/notification |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment