@hkdigital/lib-sveltekit 0.1.73 → 0.1.74

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.
@@ -2,33 +2,34 @@ declare const _default: {};
2
2
  export default _default;
3
3
  export type CacheEntry = {
4
4
  /**
5
- * The cached response
5
+ * - Cached Response object
6
6
  */
7
7
  response: Response;
8
8
  /**
9
- * Cache metadata including expiration
9
+ * - Cache entry metadata
10
10
  */
11
11
  metadata: any;
12
12
  /**
13
- * The request URL
13
+ * - Original URL
14
14
  */
15
15
  url: string;
16
16
  /**
17
- * When the entry was cached
17
+ * - When the entry was cached
18
18
  */
19
19
  timestamp: number;
20
20
  /**
21
- * When the entry expires
21
+ * - Expiration timestamp (null if no expiration)
22
22
  */
23
23
  expires: number | null;
24
24
  /**
25
- * ETag for conditional requests
25
+ * - ETag header if present
26
26
  */
27
27
  etag: string | null;
28
28
  /**
29
- * Last-Modified for conditional requests
29
+ * - Last-Modified header if present
30
30
  */
31
31
  lastModified: string | null;
32
+ cacheVersion: string | null;
32
33
  };
33
34
  export type CacheStorage = {
34
35
  /**
@@ -48,3 +49,19 @@ export type CacheStorage = {
48
49
  */
49
50
  clear: () => Promise<void>;
50
51
  };
52
+ export type IDBRequestEvent = {
53
+ /**
54
+ * - The request that generated the event
55
+ */
56
+ target: IDBRequest;
57
+ };
58
+ export type IDBVersionChangeEvent = {
59
+ /**
60
+ * - The request that generated the event
61
+ */
62
+ target: IDBOpenDBRequest;
63
+ /**
64
+ * - The transaction for database upgrade
65
+ */
66
+ transaction?: IDBTransaction;
67
+ };
@@ -1,13 +1,14 @@
1
1
 
2
2
  /**
3
3
  * @typedef {Object} CacheEntry
4
- * @property {Response} response The cached response
5
- * @property {Object} metadata Cache metadata including expiration
6
- * @property {string} url The request URL
7
- * @property {number} timestamp When the entry was cached
8
- * @property {number|null} expires When the entry expires
9
- * @property {string|null} etag ETag for conditional requests
10
- * @property {string|null} lastModified Last-Modified for conditional requests
4
+ * @property {Response} response - Cached Response object
5
+ * @property {Object} metadata - Cache entry metadata
6
+ * @property {string} url - Original URL
7
+ * @property {number} timestamp - When the entry was cached
8
+ * @property {number|null} expires - Expiration timestamp (null if no expiration)
9
+ * @property {string|null} etag - ETag header if present
10
+ * @property {string|null} lastModified - Last-Modified header if present
11
+ * @property {string|null} cacheVersion
11
12
  */
12
13
 
13
14
  /**
@@ -22,4 +23,19 @@
22
23
  * Clear all cached responses
23
24
  */
24
25
 
26
+ // > IndexedDB
27
+
28
+ /**
29
+ * @typedef {Object} IDBRequestEvent
30
+ * @property {IDBRequest} target - The request that generated the event
31
+ */
32
+
33
+ /**
34
+ * @typedef {Object} IDBVersionChangeEvent
35
+ * @property {IDBOpenDBRequest} target - The request that generated the event
36
+ * @property {IDBTransaction} [target.transaction] - The transaction for database upgrade
37
+ */
38
+
39
+ // > Export default
40
+
25
41
  export default {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hkdigital/lib-sveltekit",
3
- "version": "0.1.73",
3
+ "version": "0.1.74",
4
4
  "author": {
5
5
  "name": "HKdigital",
6
6
  "url": "https://hkdigital.nl"