Push notifications in PWA


#1

Hello Ionic Team,

Happy to see Progressive Web App(PWA) support, but I think documentation is currently a problem.
I want to send push notifications in PWA in IOS, Android and Browser. Sending push notifications using cordova native plugins is pretty easy in IOS, Android. But I am confusing how to implement push notifications in Browser. could any one give some suggestions please(I already installed cordova push plugin). Thanks in advance…


#2

This tutorial can help you to understand what you need to make, but for PWA you can forget any cordova plugins and then implement a PushManager directly with a ServiceWorker in javascript.


#3

Thank you leonardoss for your reply. I will try out this turorial and notify the ionic team if I face any problems.


#4

so does this also works on ionic ios and android app?


#5

This process is for normal angular app where we have to create service worker manually. I just want to know how can we use push notification in ionic PWA…


#6

The Ionic FCM and Firebase Messaging APIs don’t work in the browser so you’ve got to use the service worker.