Hacker News new | ask | show | jobs
by cma 860 days ago
> That means that if you’re viewing a chat thread on your PWA and you get a new message, you can’t suppress the new-message push. This is incredibly annoying for users.

Am I confused, or can't you just have the client tell the server you are viewing the thread, and suppress the push at the server side? If everything is encrypted maybe it reveals a bit of extra metadata about what you are looking at at the time though.

They went with a 10 second delay or something, but just keeping track of the user's state could be easier (you might have connectivity gaps, requiring some keepalive logic too and then something like the delay to avoid spamming them with notifications they didn't need).