Last active
March 24, 2018 06:04
-
-
Save thangman22/6c0a727a070fd0ccc10bcd0caee295e1 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
| //Import workbox ก่อน | |
| importScripts("https://storage.googleapis.com/workbox-cdn/releases/3.0.0/workbox-sw.js") | |
| workbox.routing.registerRoute( | |
| new RegExp('.*\.js'), | |
| workbox.strategies.staleWhileRevalidate({ | |
| cacheName: 'js-cache', | |
| }) | |
| ) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment