HomePhabricator
Diffusion Comm 29caae66c7b0

[web] Register service worker for notifs

Description

[web] Register service worker for notifs

Summary: We need to register a service worker to get push notifs from the browser. This diff registers the service worker from the endpoint exposed by the keyserver in one of the previous diffs on page load. For now this service worker only logs when installing and activating.

Test Plan:

  • check if service worker is correctly registered (you can check that in the browser's dev tools)
  • check that the service worker is correctly updated after changing the service worker file

Reviewers: tomek, atul, kamil, ashoat

Reviewed By: ashoat

Subscribers: ashoat

Differential Revision: https://phab.comm.dev/D6818

Details

Provenance
Michal Gniadek <michal.gniadek@swmansion.com>Authored on Feb 21 2023, 7:11 AM
Reviewer
ashoat
Differential Revision
D6818: [web] Register service worker for notifs
Parents
rCOMM20268f039fdd: [keyserver] Send web push notification
Branches
Unknown
Tags
Unknown

Event Timeline

Michal Gniadek <michal.gniadek@swmansion.com> committed rCOMM29caae66c7b0: [web] Register service worker for notifs (authored by Michal Gniadek <michal.gniadek@swmansion.com>).Mar 1 2023, 12:49 AM