service worker file for shinymobile Progressive Web App

I have a shiny app written using shinymobile and published on shinyapps.io. I am trying to set it up as a Progressive Web App so that it can be 'installed' on a device's home page. However, it is failing the Lighthouse test because it does not have a service worker registered. This apparently results in the Google Chrome icon being displayed on top of the app icon. I am unclear what I need to do to register a service worker. shinymobile::f7Init() has a serviceWorker parameter which is only described as an:

Object with service worker module parameters. (Use for PWA).

How does this parameter work? I can find no examples.

1 Like