@serwist/sw 8.0.1 → 8.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +1 -1
- package/dist/index.js +7 -1
- package/dist/index.old.cjs +7 -1
- package/package.json +14 -14
package/dist/index.d.ts
CHANGED
|
@@ -10,7 +10,7 @@ export type SerwistOptions = HandlePrecachingOptions & {
|
|
|
10
10
|
cacheId?: string | undefined;
|
|
11
11
|
clientsClaim?: boolean;
|
|
12
12
|
runtimeCaching?: RuntimeCaching[];
|
|
13
|
-
offlineAnalyticsConfig?: GoogleAnalyticsInitializeOptions;
|
|
13
|
+
offlineAnalyticsConfig?: GoogleAnalyticsInitializeOptions | boolean;
|
|
14
14
|
disableDevLogs?: boolean;
|
|
15
15
|
};
|
|
16
16
|
export declare const installSerwist: ({ precacheEntries, precacheOptions, cleanupOutdatedCaches, skipWaiting: shouldSkipWaiting, importScripts: scriptsToImport, navigationPreload, cacheId, clientsClaim: shouldClaimClients, runtimeCaching, offlineAnalyticsConfig, disableDevLogs: shouldDisableDevLogs, ...options }: SerwistOptions) => void;
|
package/dist/index.js
CHANGED
|
@@ -97,7 +97,13 @@ const installSerwist = ({ precacheEntries, precacheOptions, cleanupOutdatedCache
|
|
|
97
97
|
}
|
|
98
98
|
});
|
|
99
99
|
if (runtimeCaching !== undefined) registerRuntimeCaching(...runtimeCaching);
|
|
100
|
-
if (offlineAnalyticsConfig !== undefined)
|
|
100
|
+
if (offlineAnalyticsConfig !== undefined) {
|
|
101
|
+
if (typeof offlineAnalyticsConfig === "boolean") {
|
|
102
|
+
offlineAnalyticsConfig && initialize();
|
|
103
|
+
} else {
|
|
104
|
+
initialize(offlineAnalyticsConfig);
|
|
105
|
+
}
|
|
106
|
+
}
|
|
101
107
|
if (shouldDisableDevLogs) disableDevLogs();
|
|
102
108
|
};
|
|
103
109
|
|
package/dist/index.old.cjs
CHANGED
|
@@ -99,7 +99,13 @@ const installSerwist = ({ precacheEntries, precacheOptions, cleanupOutdatedCache
|
|
|
99
99
|
}
|
|
100
100
|
});
|
|
101
101
|
if (runtimeCaching !== undefined) registerRuntimeCaching(...runtimeCaching);
|
|
102
|
-
if (offlineAnalyticsConfig !== undefined)
|
|
102
|
+
if (offlineAnalyticsConfig !== undefined) {
|
|
103
|
+
if (typeof offlineAnalyticsConfig === "boolean") {
|
|
104
|
+
offlineAnalyticsConfig && initialize.initialize();
|
|
105
|
+
} else {
|
|
106
|
+
initialize.initialize(offlineAnalyticsConfig);
|
|
107
|
+
}
|
|
108
|
+
}
|
|
103
109
|
if (shouldDisableDevLogs) disableDevLogs();
|
|
104
110
|
};
|
|
105
111
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@serwist/sw",
|
|
3
|
-
"version": "8.0.
|
|
3
|
+
"version": "8.0.2",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"description": "This module makes it easy to get started with the Serwist service worker libraries.",
|
|
@@ -30,22 +30,22 @@
|
|
|
30
30
|
"./package.json": "./package.json"
|
|
31
31
|
},
|
|
32
32
|
"dependencies": {
|
|
33
|
-
"@serwist/background-sync": "8.0.
|
|
34
|
-
"@serwist/broadcast-update": "8.0.
|
|
35
|
-
"@serwist/cacheable-response": "8.0.
|
|
36
|
-
"@serwist/core": "8.0.
|
|
37
|
-
"@serwist/expiration": "8.0.
|
|
38
|
-
"@serwist/google-analytics": "8.0.
|
|
39
|
-
"@serwist/navigation-preload": "8.0.
|
|
40
|
-
"@serwist/precaching": "8.0.
|
|
41
|
-
"@serwist/range-requests": "8.0.
|
|
42
|
-
"@serwist/routing": "8.0.
|
|
43
|
-
"@serwist/strategies": "8.0.
|
|
33
|
+
"@serwist/background-sync": "8.0.2",
|
|
34
|
+
"@serwist/broadcast-update": "8.0.2",
|
|
35
|
+
"@serwist/cacheable-response": "8.0.2",
|
|
36
|
+
"@serwist/core": "8.0.2",
|
|
37
|
+
"@serwist/expiration": "8.0.2",
|
|
38
|
+
"@serwist/google-analytics": "8.0.2",
|
|
39
|
+
"@serwist/navigation-preload": "8.0.2",
|
|
40
|
+
"@serwist/precaching": "8.0.2",
|
|
41
|
+
"@serwist/range-requests": "8.0.2",
|
|
42
|
+
"@serwist/routing": "8.0.2",
|
|
43
|
+
"@serwist/strategies": "8.0.2"
|
|
44
44
|
},
|
|
45
45
|
"devDependencies": {
|
|
46
46
|
"rollup": "3.28.1",
|
|
47
|
-
"@serwist/build": "8.0.
|
|
48
|
-
"@serwist/constants": "8.0.
|
|
47
|
+
"@serwist/build": "8.0.2",
|
|
48
|
+
"@serwist/constants": "8.0.2"
|
|
49
49
|
},
|
|
50
50
|
"scripts": {
|
|
51
51
|
"build": "rimraf dist && cross-env NODE_ENV=production rollup --config rollup.config.js",
|