@@ -20,21 +20,23 @@ if (!self.define) {
20
20
let nextDefineUri ;
21
21
22
22
const singleRequire = ( uri , parentUri ) => {
23
- uri = new URL ( uri + '.js' , parentUri ) . href ;
24
- return (
25
- registry [ uri ] ||
26
- new Promise ( ( resolve ) => {
27
- if ( 'document' in self ) {
28
- const script = document . createElement ( 'script' ) ;
29
- script . src = uri ;
30
- script . onload = resolve ;
31
- document . head . appendChild ( script ) ;
32
- } else {
33
- nextDefineUri = uri ;
34
- importScripts ( uri ) ;
35
- resolve ( ) ;
36
- }
37
- } ) . then ( ( ) => {
23
+ uri = new URL ( uri + ".js" , parentUri ) . href ;
24
+ return registry [ uri ] || (
25
+
26
+ new Promise ( resolve => {
27
+ if ( "document" in self ) {
28
+ const script = document . createElement ( "script" ) ;
29
+ script . src = uri ;
30
+ script . onload = resolve ;
31
+ document . head . appendChild ( script ) ;
32
+ } else {
33
+ nextDefineUri = uri ;
34
+ importScripts ( uri ) ;
35
+ resolve ( ) ;
36
+ }
37
+ } )
38
+
39
+ . then ( ( ) => {
38
40
let promise = registry [ uri ] ;
39
41
if ( ! promise ) {
40
42
throw new Error ( `Module ${ uri } didn’t register its module` ) ;
@@ -45,31 +47,27 @@ if (!self.define) {
45
47
} ;
46
48
47
49
self . define = ( depsNames , factory ) => {
48
- const uri =
49
- nextDefineUri ||
50
- ( 'document' in self ? document . currentScript . src : '' ) ||
51
- location . href ;
50
+ const uri = nextDefineUri || ( "document" in self ? document . currentScript . src : "" ) || location . href ;
52
51
if ( registry [ uri ] ) {
53
52
// Module is already loading or loaded.
54
53
return ;
55
54
}
56
55
let exports = { } ;
57
- const require = ( depUri ) => singleRequire ( depUri , uri ) ;
56
+ const require = depUri => singleRequire ( depUri , uri ) ;
58
57
const specialDeps = {
59
58
module : { uri } ,
60
59
exports,
61
- require,
60
+ require
62
61
} ;
63
- registry [ uri ] = Promise . all (
64
- depsNames . map ( ( depName ) => specialDeps [ depName ] || require ( depName ) ) ,
65
- ) . then ( ( deps ) => {
62
+ registry [ uri ] = Promise . all ( depsNames . map (
63
+ depName => specialDeps [ depName ] || require ( depName )
64
+ ) ) . then ( deps => {
66
65
factory ( ...deps ) ;
67
66
return exports ;
68
67
} ) ;
69
68
} ;
70
69
}
71
- define ( [ './workbox-5357ef54' ] , function ( workbox ) {
72
- 'use strict' ;
70
+ define ( [ './workbox-5357ef54' ] , ( function ( workbox ) { 'use strict' ;
73
71
74
72
self . skipWaiting ( ) ;
75
73
workbox . clientsClaim ( ) ;
@@ -79,23 +77,16 @@ define(['./workbox-5357ef54'], function (workbox) {
79
77
* requests for URLs in the manifest.
80
78
* See https://goo.gl/S9QRab
81
79
*/
82
- workbox . precacheAndRoute (
83
- [
84
- {
85
- url : 'registerSW.js' ,
86
- revision : '3ca0b8505b4bec776b69afdba2768812' ,
87
- } ,
88
- {
89
- url : 'index.html' ,
90
- revision : '0.5v9mpiqo8c8' ,
91
- } ,
92
- ] ,
93
- { } ,
94
- ) ;
80
+ workbox . precacheAndRoute ( [ {
81
+ "url" : "registerSW.js" ,
82
+ "revision" : "3ca0b8505b4bec776b69afdba2768812"
83
+ } , {
84
+ "url" : "index.html" ,
85
+ "revision" : "0.1luf9u5i3ag"
86
+ } ] , { } ) ;
95
87
workbox . cleanupOutdatedCaches ( ) ;
96
- workbox . registerRoute (
97
- new workbox . NavigationRoute ( workbox . createHandlerBoundToURL ( 'index.html' ) , {
98
- allowlist : [ / ^ \/ $ / ] ,
99
- } ) ,
100
- ) ;
101
- } ) ;
88
+ workbox . registerRoute ( new workbox . NavigationRoute ( workbox . createHandlerBoundToURL ( "index.html" ) , {
89
+ allowlist : [ / ^ \/ $ / ]
90
+ } ) ) ;
91
+
92
+ } ) ) ;
0 commit comments