You can send local push notifications in a much simpler way, by adding this code

var options = {

body: 'Simple notification, this can not ge simpler !'

}

var n = new Notification('Simple notification', options);

if (Notification.permission !== "denied") {

Notification.requestPermission()

}

take a look at this link

https://developer.mozilla.org/en-US/docs/Web/API/Notifications_API/Using_the_Notifications_API

A 16 year old guy who loves programming

Love podcasts or audiobooks? Learn on the go with our new app.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store