serwist 10.0.0-preview.4 → 10.0.0-preview.5

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.
@@ -237,7 +237,7 @@ const finalAssertExports = process.env.NODE_ENV === "production" ? null : {
237
237
  isArrayOfClass
238
238
  };
239
239
 
240
- const logger = process.env.NODE_ENV === "production" ? null : (()=>{
240
+ const logger = process.env.NODE_ENV === "production" || typeof self === "undefined" || import.meta.env?.SSR ? null : (()=>{
241
241
  if (!("__WB_DISABLE_DEV_LOGS" in globalThis)) {
242
242
  self.__WB_DISABLE_DEV_LOGS = false;
243
243
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "serwist",
3
- "version": "10.0.0-preview.4",
3
+ "version": "10.0.0-preview.5",
4
4
  "type": "module",
5
5
  "description": "A Swiss Army knife for service workers.",
6
6
  "files": [
@@ -65,12 +65,12 @@
65
65
  },
66
66
  "dependencies": {
67
67
  "idb": "8.0.2",
68
- "@serwist/utils": "10.0.0-preview.4"
68
+ "@serwist/utils": "10.0.0-preview.5"
69
69
  },
70
70
  "devDependencies": {
71
71
  "rollup": "4.40.0",
72
72
  "typescript": "5.8.3",
73
- "@serwist/configs": "10.0.0-preview.4"
73
+ "@serwist/configs": "10.0.0-preview.5"
74
74
  },
75
75
  "peerDependencies": {
76
76
  "typescript": ">=5.0.0"
@@ -24,7 +24,7 @@ declare global {
24
24
  * before using it.
25
25
  */
26
26
  export const logger =
27
- process.env.NODE_ENV === "production"
27
+ process.env.NODE_ENV === "production" || typeof self === "undefined" || (import.meta as any).env?.SSR /** Check for SSR */
28
28
  ? null!
29
29
  : (() => {
30
30
  // Don't overwrite this value if it's already set.