Discussion: What is the best way to get users to refresh a web app?

github logo ・1 min read

I'm currently developing a Nuxt web app for our staff to use for processing orders.

At the moment, there are a lot of bugs being fixed or new features implemented.

The trouble is, the users generally keep the tab open for days on end, since they are using it constantly - and since it's Nuxt, they don't ever hard-refresh.

This means they don't get the bug fixes they asked for as soon as they have been deployed.

What is the simplest notification system for me to quickly post a 'Refresh this page to see the latest version' popup?

I'm using Nuxt, GraphQL, and Zeit deployment, so if it could trigger from a successful deploy on Zeit that would be awesome.

twitter logo DISCUSS (5)
markdown guide

Once every 5 minutes or something, the client should request the newest version number from the server. If it’s different from the one it’s currently running, it should show a popup in the corner telling the user that there’s a new version and that they should refresh.


What Next does and probably Nuxt can do if it’s not default is create a BUILD_ID, if such ID changed when the user tried to access another page then it’s hard reloaded. Maybe you could do something similar?


Do something to cause their browser to crash...


Hah. It does that already - these are the bug fixes!


You could create an event listener to trigger a popup when a service worker finds an update. Take a look at developers.google.com/web/fundamen...

Classic DEV Post from Sep 5 '19

What do you wish to know about JavaScript when you were in university?

Max Reynolds profile image

dev.to now has dark mode.

Go to the "misc" section of your settings and select night theme ❤️