Immediately Load Latest App

remotes/origin/HEAD
MengYX 5 years ago
parent 86d59f4e6f
commit f7d19e62fd
No known key found for this signature in database
GPG Key ID: E63F9C7303E8F604

@ -20,7 +20,8 @@ if (process.env.NODE_ENV === 'production') {
console.log('New content is downloading.') console.log('New content is downloading.')
}, },
updated() { updated() {
console.log('New content is available; please refresh.') console.log('New content is available.');
window.location.reload();
}, },
offline() { offline() {
console.log('No internet connection found. App is running in offline mode.') console.log('No internet connection found. App is running in offline mode.')

@ -1,4 +1,9 @@
module.exports = { module.exports = {
publicPath: '', publicPath: '',
productionSourceMap: true productionSourceMap: true,
pwa: {
workboxOptions: {
skipWaiting: true
}
}
}; };
Loading…
Cancel
Save