]>
git.immae.eu Git - github/bastienwirtz/homer.git/blob - src/registerServiceWorker.js
1 /* eslint-disable no-console */
3 import { register
} from "register-service-worker";
5 if (process
.env
.NODE_ENV
=== "production") {
6 register(`${process.env.BASE_URL}service-worker.js`, {
9 "App is being served from cache by a service worker.\n" +
10 "For more details, visit https://goo.gl/AFskqB"
14 console
.log("Service worker has been registered.");
17 console
.log("Content has been cached for offline use.");
20 console
.log("New content is downloading.");
23 console
.log("New content is available; please refresh.");
27 "No internet connection found. App is running in offline mode."
31 console
.error("Error during service worker registration:", error
);