We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 801fec2 commit daf8df1Copy full SHA for daf8df1
packages/react-scripts/template/src/registerServiceWorker.js
@@ -35,6 +35,15 @@ export default function register() {
35
if (isLocalhost) {
36
// This is running on localhost. Lets check if a service worker still exists or not.
37
checkValidServiceWorker(swUrl);
38
+
39
+ // Add some additional logging to localhost, pointing developers to the
40
+ // service worker/PWA documentation.
41
+ navigator.serviceWorker.ready.then(() => {
42
+ console.log(
43
+ 'This web app is being served cache-first by a service ' +
44
+ 'worker. To learn more, visit https://goo.gl/SC7cgQ'
45
+ );
46
+ });
47
} else {
48
// Is not local host. Just register service worker
49
registerValidSW(swUrl);
0 commit comments