Created
December 2, 2017 02:37
-
-
Save arackaf/1f81dc92bfe4a8b3bc3ab959182d72de to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
toolbox.router.get(/books$/, handleMain); | |
toolbox.router.get(/subjects$/, handleMain); | |
toolbox.router.get(/localhost:3000\/$/, handleMain); | |
toolbox.router.get(/mylibrary.io$/, handleMain); | |
function handleMain(request) { | |
return fetch(request).catch(() => { | |
return caches.match("react-redux/offline.htm", { ignoreSearch: true }); | |
}); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment