[w3c/push-api] Best practices to dismiss web push notifications cross devices (Issue #359)

Hello,

I'm working on a web application that allows receiving push notifications on different devices. I would like to ensure that when a user reads a notification on one device, it gets removed from the others.

I wanted to use subscribe with userVisibleOnly: false, but it seems that Chrome doesn't currently support it...

It seems that if no notification is sent for a "push" event at the service worker level, the browser may display a warning notification to the user indicating that it's working in the background.

I was thinking of including the IDs of my unread notifications in each push and removing any notifications that don't match before adding the new one. However, I'm still facing an issue if I have only one notification and it becomes read.

What are the current best practices to achieve this?

Have a good day.
Maxime

-- 
Reply to this email directly or view it on GitHub:
https://github.com/w3c/push-api/issues/359
You are receiving this because you are subscribed to this thread.

Message ID: <w3c/push-api/issues/359@github.com>

Received on Friday, 19 May 2023 09:57:33 UTC