mirror of
https://github.com/chinchang/web-maker.git
synced 2025-07-12 17:46:26 +02:00
service-worker-registration: add offline msg
This commit is contained in:
@ -48,6 +48,9 @@ if ('serviceWorker' in navigator && document.cookie.indexOf('wmdebug') === -1) {
|
||||
// At this point, everything has been precached.
|
||||
// It's the perfect time to display a "Content is cached for offline use." message.
|
||||
console.log('Content is now available offline!');
|
||||
if (window.alertsService) {
|
||||
window.alertsService.add('Web Maker is now ready to be used offline.');
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
||||
|
Reference in New Issue
Block a user