Closed
Description
Question: Currently, a webapp made with create-react-app
only checks for updates when it first loads using the registerServiceWorker
function. If the app is added to a phone's homescreen, it may never close, and so it never checks for new versions. Is there a recommended way to get it to check more often? For example, setting an interval and calling register
every day or so. The extreme solution would be to just call window.location.reload()
periodically, but I am hoping for a less disruptive solution. What is the best approach?