How to send Website Notification from BrowserWindow() to Windows Desktop?


#1

How do I receive notifications sent via the website and send them to Windows Desktop?

mainWindow = new BrowserWindow()
mainWindow.loadURL('https://website.that.send.notification');

#2

Could you clarify your question.
If you want receive notification from child window you might be set communication https://github.com/electron/electron/blob/master/docs/api/web-contents.md between child and parent windows then from parent(main process) you might send notification
https://electronjs.org/docs/tutorial/notifications
https://github.com/benjamindean/atom-notifier/blob/master/lib/notifier.coffee#L60


#3

Website ‘https://website.that.send.notification’ send notifications, which I want to show notifications on Windows Desktop.

Website --> Electron loadURL --> Windows Desktop


#4

I think I have a solution to the problem.

Push notifications are not currently supported in Electron