@amazon/vinyl-cache-manager 1.0.0

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.
@@ -0,0 +1,67 @@
1
+ /**
2
+ * Represents all known Cache-Control directives.
3
+ *
4
+ * https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Cache-Control
5
+ */
6
+ export type CacheControl = {
7
+ /**
8
+ * The maximum amount of time (in seconds) a resource is considered fresh.
9
+ * Example: `max-age=3600` (1 hour)
10
+ */
11
+ readonly maxAge?: number;
12
+ /**
13
+ * Requires the resource to be revalidated with the origin server before serving it from the cache.
14
+ * Example: `no-cache`
15
+ */
16
+ readonly noCache?: boolean;
17
+ /**
18
+ * Prevents the resource from being cached by any mechanism.
19
+ * Example: `no-store`
20
+ */
21
+ readonly noStore?: boolean;
22
+ /**
23
+ * Ensures that stale responses cannot be used without successful revalidation with the origin server.
24
+ * Example: `must-revalidate`
25
+ */
26
+ readonly mustRevalidate?: boolean;
27
+ /**
28
+ * Indicates the resource is cacheable by both shared and private caches.
29
+ * Example: `public`
30
+ */
31
+ readonly public?: boolean;
32
+ /**
33
+ * Indicates the resource is cacheable only by the user's browser or private caches, not shared caches.
34
+ * Example: `private`
35
+ */
36
+ readonly private?: boolean;
37
+ /**
38
+ * Indicates that the resource will not change, so it does not need to be revalidated.
39
+ * Example: `immutable`
40
+ */
41
+ readonly immutable?: boolean;
42
+ /**
43
+ * Allows serving stale responses for the specified duration (in seconds) while asynchronously revalidating the
44
+ * cache.
45
+ * Example: `stale-while-revalidate=60`
46
+ */
47
+ readonly staleWhileRevalidate?: number;
48
+ /**
49
+ * Allows serving stale responses (in seconds) if the origin server is unavailable or returns an error.
50
+ * Example: `stale-if-error=86400` (1 day)
51
+ */
52
+ readonly staleIfError?: number;
53
+ /**
54
+ * Indicates the client only wants a response from the cache and will not make a network request.
55
+ * Example: `only-if-cached`
56
+ */
57
+ readonly onlyIfCached?: boolean;
58
+ };
59
+ /**
60
+ * Parses a Cache-Control header string into a structured object.
61
+ * Handles known directives with optional numeric values.
62
+ *
63
+ * @param str - The Cache-Control header string to parse.
64
+ * @returns A CacheControl object representing the parsed directives.
65
+ */
66
+ export declare function parseCacheControl(str: string | null | undefined): CacheControl;
67
+ //# sourceMappingURL=CacheControl.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CacheControl.d.ts","sourceRoot":"","sources":["../../../../src/cacheManager/CacheControl.ts"],"names":[],"mappings":"AAKA;;;;GAIG;AACH,MAAM,MAAM,YAAY,GAAG;IACvB;;;OAGG;IACH,QAAQ,CAAC,MAAM,CAAC,EAAE,MAAM,CAAA;IAExB;;;OAGG;IACH,QAAQ,CAAC,OAAO,CAAC,EAAE,OAAO,CAAA;IAE1B;;;OAGG;IACH,QAAQ,CAAC,OAAO,CAAC,EAAE,OAAO,CAAA;IAE1B;;;OAGG;IACH,QAAQ,CAAC,cAAc,CAAC,EAAE,OAAO,CAAA;IAEjC;;;OAGG;IACH,QAAQ,CAAC,MAAM,CAAC,EAAE,OAAO,CAAA;IAEzB;;;OAGG;IACH,QAAQ,CAAC,OAAO,CAAC,EAAE,OAAO,CAAA;IAE1B;;;OAGG;IACH,QAAQ,CAAC,SAAS,CAAC,EAAE,OAAO,CAAA;IAE5B;;;;OAIG;IACH,QAAQ,CAAC,oBAAoB,CAAC,EAAE,MAAM,CAAA;IAEtC;;;OAGG;IACH,QAAQ,CAAC,YAAY,CAAC,EAAE,MAAM,CAAA;IAE9B;;;OAGG;IACH,QAAQ,CAAC,YAAY,CAAC,EAAE,OAAO,CAAA;CAClC,CAAA;AAgBD;;;;;;GAMG;AACH,wBAAgB,iBAAiB,CAC7B,GAAG,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,GAC/B,YAAY,CAqBd"}
@@ -0,0 +1,47 @@
1
+ /*
2
+ * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
3
+ * SPDX-License-Identifier: Apache-2.0
4
+ */
5
+ // Map for known directive names to their typed keys
6
+ const knownDirectives = {
7
+ 'max-age': 'maxAge',
8
+ 'no-cache': 'noCache',
9
+ 'no-store': 'noStore',
10
+ 'must-revalidate': 'mustRevalidate',
11
+ public: 'public',
12
+ private: 'private',
13
+ immutable: 'immutable',
14
+ 'stale-while-revalidate': 'staleWhileRevalidate',
15
+ 'stale-if-error': 'staleIfError',
16
+ 'only-if-cached': 'onlyIfCached',
17
+ };
18
+ /**
19
+ * Parses a Cache-Control header string into a structured object.
20
+ * Handles known directives with optional numeric values.
21
+ *
22
+ * @param str - The Cache-Control header string to parse.
23
+ * @returns A CacheControl object representing the parsed directives.
24
+ */
25
+ export function parseCacheControl(str) {
26
+ if (!str)
27
+ return {};
28
+ const directives = {};
29
+ str.split(',').forEach((part) => {
30
+ const [key, value] = part.trim().split('=');
31
+ const directiveKey = key.trim().toLowerCase(); // Ensure case-insensitivity
32
+ const typedKey = knownDirectives[directiveKey];
33
+ if (typedKey) {
34
+ // Parse the value or set to true for boolean directives
35
+ if (value === undefined) {
36
+ directives[typedKey] = true;
37
+ }
38
+ else {
39
+ const numericValue = parseInt(value, 10);
40
+ directives[typedKey] = isNaN(numericValue)
41
+ ? value
42
+ : numericValue;
43
+ }
44
+ }
45
+ });
46
+ return directives;
47
+ }
@@ -0,0 +1,119 @@
1
+ import { type CacheControl } from './CacheControl';
2
+ export declare const DEFAULT_CACHE_NAME = "offlineCache";
3
+ export declare const DEFAULT_PURGE_AFTER_STALE: number;
4
+ /**
5
+ * If the cache control options set the onlyIfCached directive and the request is not cached, an error will be thrown.
6
+ */
7
+ export declare const NOT_CACHED_ERROR = "Not cached";
8
+ export type CacheManagerOptions = {
9
+ /**
10
+ * The name of the cache key.
11
+ */
12
+ readonly name?: string;
13
+ /**
14
+ * The Fetch from network method. Defaults to window.fetch.
15
+ */
16
+ readonly requestFromNetwork?: Fetch;
17
+ };
18
+ type Fetch = (request: RequestInfo) => Promise<Response>;
19
+ export type CacheEntryOptions = {
20
+ /**
21
+ * If set, the response will be cached under this identifier, not based on the request.
22
+ * This is required for caching POST requests.
23
+ */
24
+ readonly cacheKey?: string | null | undefined;
25
+ /**
26
+ * Cache control directive defaults.
27
+ * These will be used unless overridden by the response headers or the cache control overrides.
28
+ *
29
+ * CacheControl directives will be overwritten in the order:
30
+ * - cacheControlDefaults
31
+ * - response headers
32
+ * - cacheControlOverrides
33
+ */
34
+ readonly cacheControlDefaults?: CacheControl;
35
+ /**
36
+ * Allows the client to set cache control overrides. This object is merged with the actual cache control header.
37
+ *
38
+ * For example, to allow cached items to be used 1 day after they are stale while asynchronously revalidating
39
+ * the cache, set `{ staleWhileRevalidate: 24 * 60 * 60 }`
40
+ *
41
+ * These overrides do not change the header cached, only how the cached header is read.
42
+ * If noStore is true, the entry will not be cached.
43
+ */
44
+ readonly cacheControlOverrides?: CacheControl;
45
+ /**
46
+ * If set, checks the response if it should be used. This affects whether to cache and whether to use the
47
+ * cached fallback.
48
+ */
49
+ readonly responseIsValid?: (response: Response) => Promise<boolean>;
50
+ };
51
+ export type CacheCleanOptions = {
52
+ /**
53
+ * The number of seconds after an entry becomes stale before it should be removed from the cache.
54
+ * Default: 7 * 24 * 60 * 60 (7 days).
55
+ * If the cached entry has a stale-while-revalidate cache control directive, this will be ignored.
56
+ */
57
+ readonly purgeAfterStale?: number;
58
+ };
59
+ export interface CacheManagerDeps {
60
+ /**
61
+ * The cache storages api.
62
+ * Default: window.caches
63
+ */
64
+ readonly caches?: CacheStorage;
65
+ /**
66
+ * Creates a Headers object
67
+ */
68
+ readonly headersFactory?: (headersInit?: HeadersInit) => Headers;
69
+ /**
70
+ * Creates a Response object
71
+ */
72
+ readonly responseFactory?: (body?: BodyInit | null, init?: ResponseInit) => Response;
73
+ }
74
+ export declare class CacheManager {
75
+ readonly name: string;
76
+ private readonly caches;
77
+ private cache;
78
+ private readonly fetch;
79
+ /**
80
+ * If set, when asynchronous caching has failed, this callback will be invoked.
81
+ * This is not invoked when a promise rejects during an operation.
82
+ */
83
+ onError?: (error: Error) => void;
84
+ constructor(options?: CacheManagerOptions, deps?: CacheManagerDeps);
85
+ private readonly errorHandler;
86
+ /**
87
+ * Caches a response with added expiry headers.
88
+ */
89
+ put(cacheId: RequestInfo, response: Response): Promise<Response>;
90
+ /**
91
+ * Deletes the request from this cache.
92
+ *
93
+ * @param cacheId The request or cache id used as the cache key.
94
+ */
95
+ delete(cacheId: RequestInfo): Promise<boolean>;
96
+ /**
97
+ * Resolves to true if the request is cached.
98
+ *
99
+ * @param cacheId
100
+ */
101
+ has(cacheId: RequestInfo): Promise<boolean>;
102
+ get(request: RequestInfo, options?: CacheEntryOptions): Promise<Response>;
103
+ /**
104
+ * Returns a Response if it exists in cache.
105
+ *
106
+ * @param request
107
+ */
108
+ private getCached;
109
+ /**
110
+ * @returns a promise that resolves to true if the Cache object is found and deleted, and false otherwise.
111
+ */
112
+ clear(): Promise<boolean>;
113
+ /**
114
+ * Cleans stale items from the cache.
115
+ */
116
+ clean(options?: CacheCleanOptions): Promise<void>;
117
+ }
118
+ export {};
119
+ //# sourceMappingURL=CacheManager.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CacheManager.d.ts","sourceRoot":"","sources":["../../../../src/cacheManager/CacheManager.ts"],"names":[],"mappings":"AAWA,OAAO,EAAE,KAAK,YAAY,EAAqB,MAAM,gBAAgB,CAAA;AAErE,eAAO,MAAM,kBAAkB,iBAAiB,CAAA;AAChD,eAAO,MAAM,yBAAyB,QAAmB,CAAA;AAEzD;;GAEG;AACH,eAAO,MAAM,gBAAgB,eAAe,CAAA;AAE5C,MAAM,MAAM,mBAAmB,GAAG;IAC9B;;OAEG;IACH,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,CAAA;IAEtB;;OAEG;IACH,QAAQ,CAAC,kBAAkB,CAAC,EAAE,KAAK,CAAA;CACtC,CAAA;AAED,KAAK,KAAK,GAAG,CAAC,OAAO,EAAE,WAAW,KAAK,OAAO,CAAC,QAAQ,CAAC,CAAA;AAaxD,MAAM,MAAM,iBAAiB,GAAG;IAC5B;;;OAGG;IACH,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,CAAA;IAE7C;;;;;;;;OAQG;IACH,QAAQ,CAAC,oBAAoB,CAAC,EAAE,YAAY,CAAA;IAE5C;;;;;;;;OAQG;IACH,QAAQ,CAAC,qBAAqB,CAAC,EAAE,YAAY,CAAA;IAE7C;;;OAGG;IACH,QAAQ,CAAC,eAAe,CAAC,EAAE,CAAC,QAAQ,EAAE,QAAQ,KAAK,OAAO,CAAC,OAAO,CAAC,CAAA;CACtE,CAAA;AAED,MAAM,MAAM,iBAAiB,GAAG;IAC5B;;;;OAIG;IACH,QAAQ,CAAC,eAAe,CAAC,EAAE,MAAM,CAAA;CACpC,CAAA;AAED,MAAM,WAAW,gBAAgB;IAC7B;;;OAGG;IACH,QAAQ,CAAC,MAAM,CAAC,EAAE,YAAY,CAAA;IAE9B;;OAEG;IACH,QAAQ,CAAC,cAAc,CAAC,EAAE,CAAC,WAAW,CAAC,EAAE,WAAW,KAAK,OAAO,CAAA;IAEhE;;OAEG;IACH,QAAQ,CAAC,eAAe,CAAC,EAAE,CACvB,IAAI,CAAC,EAAE,QAAQ,GAAG,IAAI,EACtB,IAAI,CAAC,EAAE,YAAY,KAClB,QAAQ,CAAA;CAChB;AAED,qBAAa,YAAY;IACrB,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAA;IAErB,OAAO,CAAC,QAAQ,CAAC,MAAM,CAAc;IACrC,OAAO,CAAC,KAAK,CAAgB;IAC7B,OAAO,CAAC,QAAQ,CAAC,KAAK,CAAO;IAE7B;;;OAGG;IACH,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,KAAK,KAAK,IAAI,CAAA;gBAEpB,OAAO,CAAC,EAAE,mBAAmB,EAAE,IAAI,CAAC,EAAE,gBAAgB;IAQlE,OAAO,CAAC,QAAQ,CAAC,YAAY,CAE5B;IAED;;OAEG;IACG,GAAG,CAAC,OAAO,EAAE,WAAW,EAAE,QAAQ,EAAE,QAAQ,GAAG,OAAO,CAAC,QAAQ,CAAC;IAqBtE;;;;OAIG;IACG,MAAM,CAAC,OAAO,EAAE,WAAW,GAAG,OAAO,CAAC,OAAO,CAAC;IAKpD;;;;OAIG;IACG,GAAG,CAAC,OAAO,EAAE,WAAW,GAAG,OAAO,CAAC,OAAO,CAAC;IAI3C,GAAG,CACL,OAAO,EAAE,WAAW,EACpB,OAAO,CAAC,EAAE,iBAAiB,GAC5B,OAAO,CAAC,QAAQ,CAAC;IAsEpB;;;;OAIG;YACW,SAAS;IAOvB;;OAEG;IACG,KAAK,IAAI,OAAO,CAAC,OAAO,CAAC;IAM/B;;OAEG;IACG,KAAK,CAAC,OAAO,CAAC,EAAE,iBAAiB;CA2B1C"}
@@ -0,0 +1,221 @@
1
+ /*
2
+ * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
3
+ * SPDX-License-Identifier: Apache-2.0
4
+ */
5
+ /*
6
+ * Offline utility that can be shared between the service worker and application.
7
+ * Note - this should not use any dependencies; the bundled service worker must
8
+ * be lightweight.
9
+ */
10
+ import { parseCacheControl } from './CacheControl';
11
+ export const DEFAULT_CACHE_NAME = 'offlineCache';
12
+ export const DEFAULT_PURGE_AFTER_STALE = 7 * 24 * 60 * 60;
13
+ /**
14
+ * If the cache control options set the onlyIfCached directive and the request is not cached, an error will be thrown.
15
+ */
16
+ export const NOT_CACHED_ERROR = 'Not cached';
17
+ /**
18
+ * A prefix for cache keys in order to guarantee they can be used as cache keys.
19
+ * WebKit browsers only allow http/https cache keys.
20
+ */
21
+ const CACHE_KEY_PREFIX = 'https://cache/';
22
+ /**
23
+ * A custom header for storing the timestamp at which the entry was cached.
24
+ */
25
+ const CACHED_TIMESTAMP_HEADER = 'X-Cached-Timestamp';
26
+ export class CacheManager {
27
+ name;
28
+ caches;
29
+ cache;
30
+ fetch;
31
+ /**
32
+ * If set, when asynchronous caching has failed, this callback will be invoked.
33
+ * This is not invoked when a promise rejects during an operation.
34
+ */
35
+ onError;
36
+ constructor(options, deps) {
37
+ this.caches = deps?.caches ?? caches;
38
+ this.name = options?.name ?? DEFAULT_CACHE_NAME;
39
+ this.cache = this.caches.open(this.name);
40
+ this.fetch =
41
+ options?.requestFromNetwork ?? ((request) => fetch(request));
42
+ }
43
+ errorHandler = (error) => {
44
+ this.onError?.(error);
45
+ };
46
+ /**
47
+ * Caches a response with added expiry headers.
48
+ */
49
+ async put(cacheId, response) {
50
+ if (response.bodyUsed)
51
+ throw new Error(`cannot cache request, body already used`);
52
+ const clonedResponse = response.clone();
53
+ // Add a timestamp header
54
+ const headers = new Headers(clonedResponse.headers);
55
+ headers.append(CACHED_TIMESTAMP_HEADER, Date.now().toString());
56
+ const responseWithHeader = new Response(clonedResponse.body, {
57
+ status: clonedResponse.status,
58
+ statusText: clonedResponse.statusText,
59
+ headers,
60
+ });
61
+ const cache = await this.cache;
62
+ await cache.put(cacheId, responseWithHeader);
63
+ return response;
64
+ }
65
+ /**
66
+ * Deletes the request from this cache.
67
+ *
68
+ * @param cacheId The request or cache id used as the cache key.
69
+ */
70
+ async delete(cacheId) {
71
+ const cache = await this.cache;
72
+ return await cache.delete(cacheId);
73
+ }
74
+ /**
75
+ * Resolves to true if the request is cached.
76
+ *
77
+ * @param cacheId
78
+ */
79
+ async has(cacheId) {
80
+ return (await this.getCached(cacheId)) != null;
81
+ }
82
+ async get(request, options) {
83
+ const cache = await this.cache;
84
+ const cacheId = options?.cacheKey
85
+ ? CACHE_KEY_PREFIX + options.cacheKey
86
+ : request;
87
+ let cached;
88
+ if (options?.cacheControlOverrides?.noStore) {
89
+ this.delete(cacheId).catch(this.errorHandler);
90
+ cached = undefined;
91
+ }
92
+ else {
93
+ cached = await cache.match(cacheId);
94
+ }
95
+ const cacheControlOptions = {
96
+ defaults: options?.cacheControlDefaults,
97
+ overrides: options?.cacheControlOverrides,
98
+ };
99
+ const responseIsValid = async (response) => {
100
+ return (response.ok &&
101
+ (options?.responseIsValid == null ||
102
+ (await options.responseIsValid(response.clone()))));
103
+ };
104
+ const fetchAndMaybeCache = async () => {
105
+ return this.fetch(request).then(async (response) => {
106
+ const cacheControl = calculateCacheControl(response, cacheControlOptions);
107
+ if (!cacheControl.noStore &&
108
+ isCacheableRequestKey(cacheId) &&
109
+ (await responseIsValid(response))) {
110
+ this.put(cacheId, response).catch(this.errorHandler);
111
+ }
112
+ return response;
113
+ });
114
+ };
115
+ const cacheControl = calculateCacheControl(cached, cacheControlOptions);
116
+ const cacheBehavior = calculateCacheBehavior(cacheControl, getCachedTimestamp(cached));
117
+ if (cacheBehavior.preferCache) {
118
+ if (cacheBehavior.reevaluate) {
119
+ fetchAndMaybeCache().catch(this.errorHandler);
120
+ }
121
+ return cached;
122
+ }
123
+ else {
124
+ if (!cacheBehavior.allowNetwork && !cached) {
125
+ throw new Error(NOT_CACHED_ERROR);
126
+ }
127
+ // Prefer a network response. If the network response isn't valid, return the cached value.
128
+ const response = await fetchAndMaybeCache().catch((error) => {
129
+ if (!cacheBehavior.allowCache || !cached)
130
+ throw error;
131
+ else
132
+ return cached;
133
+ });
134
+ const ok = await responseIsValid(response);
135
+ return !ok ? (cached ?? response) : response;
136
+ }
137
+ }
138
+ /**
139
+ * Returns a Response if it exists in cache.
140
+ *
141
+ * @param request
142
+ */
143
+ async getCached(request) {
144
+ const cache = await this.cache;
145
+ return await cache.match(request);
146
+ }
147
+ /**
148
+ * @returns a promise that resolves to true if the Cache object is found and deleted, and false otherwise.
149
+ */
150
+ async clear() {
151
+ const deleted = await this.caches.delete(this.name);
152
+ this.cache = this.caches.open(this.name);
153
+ return deleted;
154
+ }
155
+ /**
156
+ * Cleans stale items from the cache.
157
+ */
158
+ async clean(options) {
159
+ const cache = await this.cache;
160
+ const cacheControlOptions = {
161
+ defaults: {
162
+ // Unless the cached entry has a stale-while-revalidate directive, use this default.
163
+ staleWhileRevalidate: options?.purgeAfterStale ?? DEFAULT_PURGE_AFTER_STALE,
164
+ },
165
+ overrides: {
166
+ noStore: false,
167
+ },
168
+ };
169
+ for (const key of await cache.keys()) {
170
+ const cached = await cache.match(key);
171
+ const cacheControl = calculateCacheControl(cached, cacheControlOptions);
172
+ const { preferCache } = calculateCacheBehavior(cacheControl, getCachedTimestamp(cached));
173
+ if (!preferCache) {
174
+ await cache.delete(key);
175
+ }
176
+ }
177
+ }
178
+ }
179
+ function calculateCacheControl(cached, options) {
180
+ const cacheControl = cached
181
+ ? parseCacheControl(cached.headers.get('Cache-Control'))
182
+ : {};
183
+ return {
184
+ ...options.defaults,
185
+ ...cacheControl,
186
+ ...options.overrides,
187
+ };
188
+ }
189
+ function calculateCacheBehavior(cacheControl, cachedTimestamp) {
190
+ const allowCache = !(cacheControl.noStore ?? false);
191
+ const maxAge = cacheControl.maxAge ?? 0;
192
+ const staleAt = maxAge * 1000 + (cachedTimestamp ?? Number.NEGATIVE_INFINITY);
193
+ const now = Date.now();
194
+ const isFresh = staleAt > now;
195
+ const immutable = cacheControl.immutable ?? false;
196
+ const allowNetwork = !cacheControl.onlyIfCached;
197
+ const reevaluate = allowNetwork && !immutable && (cacheControl.mustRevalidate || !isFresh);
198
+ // If the entry is past its max age and there is staleWhileRevalidate set, allow the cached entry to be used
199
+ // staleWhileRevalidate seconds after maxAge.
200
+ const staleWhileRevalidate = cacheControl.staleWhileRevalidate ?? 0;
201
+ const preferCache = allowCache &&
202
+ (isFresh || staleAt + staleWhileRevalidate * 1000 > now || immutable);
203
+ return {
204
+ preferCache,
205
+ reevaluate,
206
+ allowCache,
207
+ allowNetwork,
208
+ };
209
+ }
210
+ /**
211
+ * Returns true if the request can be used as a Cache key.
212
+ */
213
+ function isCacheableRequestKey(request) {
214
+ return typeof request === 'string' || request.method === 'GET';
215
+ }
216
+ function getCachedTimestamp(cached) {
217
+ const timestampHeader = cached?.headers.get(CACHED_TIMESTAMP_HEADER);
218
+ if (!timestampHeader)
219
+ return undefined;
220
+ return parseInt(timestampHeader, 10);
221
+ }
@@ -0,0 +1,4 @@
1
+ /** Auto-generated from build scripts */
2
+ export * from './cacheManager/CacheManager';
3
+ export * from './cacheManager/CacheControl';
4
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/index.ts"],"names":[],"mappings":"AAAA,wCAAwC;AACxC,cAAc,6BAA6B,CAAA;AAC3C,cAAc,6BAA6B,CAAA"}
@@ -0,0 +1,3 @@
1
+ /** Auto-generated from build scripts */
2
+ export * from './cacheManager/CacheManager';
3
+ export * from './cacheManager/CacheControl';
@@ -0,0 +1 @@
1
+ {"fileNames":["../../../../../node_modules/typescript/lib/lib.es5.d.ts","../../../../../node_modules/typescript/lib/lib.es2015.d.ts","../../../../../node_modules/typescript/lib/lib.es2016.d.ts","../../../../../node_modules/typescript/lib/lib.es2017.d.ts","../../../../../node_modules/typescript/lib/lib.es2018.d.ts","../../../../../node_modules/typescript/lib/lib.es2019.d.ts","../../../../../node_modules/typescript/lib/lib.es2020.d.ts","../../../../../node_modules/typescript/lib/lib.dom.d.ts","../../../../../node_modules/typescript/lib/lib.dom.iterable.d.ts","../../../../../node_modules/typescript/lib/lib.es2015.core.d.ts","../../../../../node_modules/typescript/lib/lib.es2015.collection.d.ts","../../../../../node_modules/typescript/lib/lib.es2015.generator.d.ts","../../../../../node_modules/typescript/lib/lib.es2015.iterable.d.ts","../../../../../node_modules/typescript/lib/lib.es2015.promise.d.ts","../../../../../node_modules/typescript/lib/lib.es2015.proxy.d.ts","../../../../../node_modules/typescript/lib/lib.es2015.reflect.d.ts","../../../../../node_modules/typescript/lib/lib.es2015.symbol.d.ts","../../../../../node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts","../../../../../node_modules/typescript/lib/lib.es2016.array.include.d.ts","../../../../../node_modules/typescript/lib/lib.es2016.intl.d.ts","../../../../../node_modules/typescript/lib/lib.es2017.arraybuffer.d.ts","../../../../../node_modules/typescript/lib/lib.es2017.date.d.ts","../../../../../node_modules/typescript/lib/lib.es2017.object.d.ts","../../../../../node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts","../../../../../node_modules/typescript/lib/lib.es2017.string.d.ts","../../../../../node_modules/typescript/lib/lib.es2017.intl.d.ts","../../../../../node_modules/typescript/lib/lib.es2017.typedarrays.d.ts","../../../../../node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts","../../../../../node_modules/typescript/lib/lib.es2018.asynciterable.d.ts","../../../../../node_modules/typescript/lib/lib.es2018.intl.d.ts","../../../../../node_modules/typescript/lib/lib.es2018.promise.d.ts","../../../../../node_modules/typescript/lib/lib.es2018.regexp.d.ts","../../../../../node_modules/typescript/lib/lib.es2019.array.d.ts","../../../../../node_modules/typescript/lib/lib.es2019.object.d.ts","../../../../../node_modules/typescript/lib/lib.es2019.string.d.ts","../../../../../node_modules/typescript/lib/lib.es2019.symbol.d.ts","../../../../../node_modules/typescript/lib/lib.es2019.intl.d.ts","../../../../../node_modules/typescript/lib/lib.es2020.bigint.d.ts","../../../../../node_modules/typescript/lib/lib.es2020.date.d.ts","../../../../../node_modules/typescript/lib/lib.es2020.promise.d.ts","../../../../../node_modules/typescript/lib/lib.es2020.sharedmemory.d.ts","../../../../../node_modules/typescript/lib/lib.es2020.string.d.ts","../../../../../node_modules/typescript/lib/lib.es2020.symbol.wellknown.d.ts","../../../../../node_modules/typescript/lib/lib.es2020.intl.d.ts","../../../../../node_modules/typescript/lib/lib.es2020.number.d.ts","../../../../../node_modules/typescript/lib/lib.decorators.d.ts","../../../../../node_modules/typescript/lib/lib.decorators.legacy.d.ts","../../../src/cachemanager/cachecontrol.ts","../../../src/cachemanager/cachemanager.ts","../../../src/index.ts","../../../../../node_modules/@types/node/compatibility/disposable.d.ts","../../../../../node_modules/@types/node/compatibility/indexable.d.ts","../../../../../node_modules/@types/node/compatibility/iterators.d.ts","../../../../../node_modules/@types/node/compatibility/index.d.ts","../../../../../node_modules/@types/node/globals.typedarray.d.ts","../../../../../node_modules/@types/node/buffer.buffer.d.ts","../../../../../node_modules/@types/node/globals.d.ts","../../../../../node_modules/@types/node/web-globals/abortcontroller.d.ts","../../../../../node_modules/@types/node/web-globals/domexception.d.ts","../../../../../node_modules/@types/node/web-globals/events.d.ts","../../../../../node_modules/buffer/index.d.ts","../../../../../node_modules/undici-types/header.d.ts","../../../../../node_modules/undici-types/readable.d.ts","../../../../../node_modules/undici-types/file.d.ts","../../../../../node_modules/undici-types/fetch.d.ts","../../../../../node_modules/undici-types/formdata.d.ts","../../../../../node_modules/undici-types/connector.d.ts","../../../../../node_modules/undici-types/client.d.ts","../../../../../node_modules/undici-types/errors.d.ts","../../../../../node_modules/undici-types/dispatcher.d.ts","../../../../../node_modules/undici-types/global-dispatcher.d.ts","../../../../../node_modules/undici-types/global-origin.d.ts","../../../../../node_modules/undici-types/pool-stats.d.ts","../../../../../node_modules/undici-types/pool.d.ts","../../../../../node_modules/undici-types/handlers.d.ts","../../../../../node_modules/undici-types/balanced-pool.d.ts","../../../../../node_modules/undici-types/agent.d.ts","../../../../../node_modules/undici-types/mock-interceptor.d.ts","../../../../../node_modules/undici-types/mock-agent.d.ts","../../../../../node_modules/undici-types/mock-client.d.ts","../../../../../node_modules/undici-types/mock-pool.d.ts","../../../../../node_modules/undici-types/mock-errors.d.ts","../../../../../node_modules/undici-types/proxy-agent.d.ts","../../../../../node_modules/undici-types/env-http-proxy-agent.d.ts","../../../../../node_modules/undici-types/retry-handler.d.ts","../../../../../node_modules/undici-types/retry-agent.d.ts","../../../../../node_modules/undici-types/api.d.ts","../../../../../node_modules/undici-types/interceptors.d.ts","../../../../../node_modules/undici-types/util.d.ts","../../../../../node_modules/undici-types/cookies.d.ts","../../../../../node_modules/undici-types/patch.d.ts","../../../../../node_modules/undici-types/websocket.d.ts","../../../../../node_modules/undici-types/eventsource.d.ts","../../../../../node_modules/undici-types/filereader.d.ts","../../../../../node_modules/undici-types/diagnostics-channel.d.ts","../../../../../node_modules/undici-types/content-type.d.ts","../../../../../node_modules/undici-types/cache.d.ts","../../../../../node_modules/undici-types/index.d.ts","../../../../../node_modules/@types/node/web-globals/fetch.d.ts","../../../../../node_modules/@types/node/assert.d.ts","../../../../../node_modules/@types/node/assert/strict.d.ts","../../../../../node_modules/@types/node/async_hooks.d.ts","../../../../../node_modules/@types/node/buffer.d.ts","../../../../../node_modules/@types/node/child_process.d.ts","../../../../../node_modules/@types/node/cluster.d.ts","../../../../../node_modules/@types/node/console.d.ts","../../../../../node_modules/@types/node/constants.d.ts","../../../../../node_modules/@types/node/crypto.d.ts","../../../../../node_modules/@types/node/dgram.d.ts","../../../../../node_modules/@types/node/diagnostics_channel.d.ts","../../../../../node_modules/@types/node/dns.d.ts","../../../../../node_modules/@types/node/dns/promises.d.ts","../../../../../node_modules/@types/node/domain.d.ts","../../../../../node_modules/@types/node/events.d.ts","../../../../../node_modules/@types/node/fs.d.ts","../../../../../node_modules/@types/node/fs/promises.d.ts","../../../../../node_modules/@types/node/http.d.ts","../../../../../node_modules/@types/node/http2.d.ts","../../../../../node_modules/@types/node/https.d.ts","../../../../../node_modules/@types/node/inspector.generated.d.ts","../../../../../node_modules/@types/node/module.d.ts","../../../../../node_modules/@types/node/net.d.ts","../../../../../node_modules/@types/node/os.d.ts","../../../../../node_modules/@types/node/path.d.ts","../../../../../node_modules/@types/node/perf_hooks.d.ts","../../../../../node_modules/@types/node/process.d.ts","../../../../../node_modules/@types/node/punycode.d.ts","../../../../../node_modules/@types/node/querystring.d.ts","../../../../../node_modules/@types/node/readline.d.ts","../../../../../node_modules/@types/node/readline/promises.d.ts","../../../../../node_modules/@types/node/repl.d.ts","../../../../../node_modules/@types/node/sea.d.ts","../../../../../node_modules/@types/node/stream.d.ts","../../../../../node_modules/@types/node/stream/promises.d.ts","../../../../../node_modules/@types/node/stream/consumers.d.ts","../../../../../node_modules/@types/node/stream/web.d.ts","../../../../../node_modules/@types/node/string_decoder.d.ts","../../../../../node_modules/@types/node/test.d.ts","../../../../../node_modules/@types/node/timers.d.ts","../../../../../node_modules/@types/node/timers/promises.d.ts","../../../../../node_modules/@types/node/tls.d.ts","../../../../../node_modules/@types/node/trace_events.d.ts","../../../../../node_modules/@types/node/tty.d.ts","../../../../../node_modules/@types/node/url.d.ts","../../../../../node_modules/@types/node/util.d.ts","../../../../../node_modules/@types/node/v8.d.ts","../../../../../node_modules/@types/node/vm.d.ts","../../../../../node_modules/@types/node/wasi.d.ts","../../../../../node_modules/@types/node/worker_threads.d.ts","../../../../../node_modules/@types/node/zlib.d.ts","../../../../../node_modules/@types/node/index.d.ts"],"fileIdsList":[[56,100,103],[56,102,103],[103],[56,103,108,136],[56,103,104,109,114,122,133,144],[56,103,104,105,114,122],[56,103],[51,52,53,56,103],[56,103,106,145],[56,103,107,108,115,123],[56,103,108,133,141],[56,103,109,111,114,122],[56,102,103,110],[56,103,111,112],[56,103,113,114],[56,102,103,114],[56,103,114,115,116,133,144],[56,103,114,115,116,129,133,136],[56,103,111,114,117,122,133,144],[56,103,114,115,117,118,122,133,141,144],[56,103,117,119,133,141,144],[54,55,56,57,58,59,60,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150],[56,103,114,120],[56,103,121,144,149],[56,103,111,114,122,133],[56,103,123],[56,103,124],[56,102,103,125],[56,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150],[56,103,127],[56,103,128],[56,103,114,129,130],[56,103,129,131,145,147],[56,103,114,133,134,136],[56,103,135,136],[56,103,133,134],[56,103,136],[56,103,137],[56,100,103,133,138],[56,103,114,139,140],[56,103,139,140],[56,103,108,122,133,141],[56,103,142],[56,103,122,143],[56,103,117,128,144],[56,103,108,145],[56,103,133,146],[56,103,121,147],[56,103,148],[56,98,103],[56,98,103,114,116,125,133,136,144,147,149],[56,103,133,150],[56,70,74,103,144],[56,70,103,133,144],[56,65,103],[56,67,70,103,141,144],[56,103,122,141],[56,103,151],[56,65,103,151],[56,67,70,103,122,144],[56,62,63,66,69,103,114,133,144],[56,70,77,103],[56,62,68,103],[56,70,91,92,103],[56,66,70,103,136,144,151],[56,91,103,151],[56,64,65,103,151],[56,70,103],[56,64,65,66,67,68,69,70,71,72,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,92,93,94,95,96,97,103],[56,70,85,103],[56,70,77,78,103],[56,68,70,78,79,103],[56,69,103],[56,62,65,70,103],[56,70,74,78,79,103],[56,74,103],[56,68,70,73,103,144],[56,62,67,70,77,103],[56,103,133],[56,65,70,91,103,149,151],[48,56,103],[48,49,56,103]],"fileInfos":[{"version":"c430d44666289dae81f30fa7b2edebf186ecc91a2d4c71266ea6ae76388792e1","affectsGlobalScope":true,"impliedFormat":1},{"version":"45b7ab580deca34ae9729e97c13cfd999df04416a79116c3bfb483804f85ded4","impliedFormat":1},{"version":"3facaf05f0c5fc569c5649dd359892c98a85557e3e0c847964caeb67076f4d75","impliedFormat":1},{"version":"e44bb8bbac7f10ecc786703fe0a6a4b952189f908707980ba8f3c8975a760962","impliedFormat":1},{"version":"5e1c4c362065a6b95ff952c0eab010f04dcd2c3494e813b493ecfd4fcb9fc0d8","impliedFormat":1},{"version":"68d73b4a11549f9c0b7d352d10e91e5dca8faa3322bfb77b661839c42b1ddec7","impliedFormat":1},{"version":"5efce4fc3c29ea84e8928f97adec086e3dc876365e0982cc8479a07954a3efd4","impliedFormat":1},{"version":"080941d9f9ff9307f7e27a83bcd888b7c8270716c39af943532438932ec1d0b9","affectsGlobalScope":true,"impliedFormat":1},{"version":"2e80ee7a49e8ac312cc11b77f1475804bee36b3b2bc896bead8b6e1266befb43","affectsGlobalScope":true,"impliedFormat":1},{"version":"c57796738e7f83dbc4b8e65132f11a377649c00dd3eee333f672b8f0a6bea671","affectsGlobalScope":true,"impliedFormat":1},{"version":"dc2df20b1bcdc8c2d34af4926e2c3ab15ffe1160a63e58b7e09833f616efff44","affectsGlobalScope":true,"impliedFormat":1},{"version":"515d0b7b9bea2e31ea4ec968e9edd2c39d3eebf4a2d5cbd04e88639819ae3b71","affectsGlobalScope":true,"impliedFormat":1},{"version":"0559b1f683ac7505ae451f9a96ce4c3c92bdc71411651ca6ddb0e88baaaad6a3","affectsGlobalScope":true,"impliedFormat":1},{"version":"0dc1e7ceda9b8b9b455c3a2d67b0412feab00bd2f66656cd8850e8831b08b537","affectsGlobalScope":true,"impliedFormat":1},{"version":"ce691fb9e5c64efb9547083e4a34091bcbe5bdb41027e310ebba8f7d96a98671","affectsGlobalScope":true,"impliedFormat":1},{"version":"8d697a2a929a5fcb38b7a65594020fcef05ec1630804a33748829c5ff53640d0","affectsGlobalScope":true,"impliedFormat":1},{"version":"4ff2a353abf8a80ee399af572debb8faab2d33ad38c4b4474cff7f26e7653b8d","affectsGlobalScope":true,"impliedFormat":1},{"version":"fb0f136d372979348d59b3f5020b4cdb81b5504192b1cacff5d1fbba29378aa1","affectsGlobalScope":true,"impliedFormat":1},{"version":"d15bea3d62cbbdb9797079416b8ac375ae99162a7fba5de2c6c505446486ac0a","affectsGlobalScope":true,"impliedFormat":1},{"version":"68d18b664c9d32a7336a70235958b8997ebc1c3b8505f4f1ae2b7e7753b87618","affectsGlobalScope":true,"impliedFormat":1},{"version":"eb3d66c8327153d8fa7dd03f9c58d351107fe824c79e9b56b462935176cdf12a","affectsGlobalScope":true,"impliedFormat":1},{"version":"38f0219c9e23c915ef9790ab1d680440d95419ad264816fa15009a8851e79119","affectsGlobalScope":true,"impliedFormat":1},{"version":"69ab18c3b76cd9b1be3d188eaf8bba06112ebbe2f47f6c322b5105a6fbc45a2e","affectsGlobalScope":true,"impliedFormat":1},{"version":"a680117f487a4d2f30ea46f1b4b7f58bef1480456e18ba53ee85c2746eeca012","affectsGlobalScope":true,"impliedFormat":1},{"version":"2f11ff796926e0832f9ae148008138ad583bd181899ab7dd768a2666700b1893","affectsGlobalScope":true,"impliedFormat":1},{"version":"4de680d5bb41c17f7f68e0419412ca23c98d5749dcaaea1896172f06435891fc","affectsGlobalScope":true,"impliedFormat":1},{"version":"954296b30da6d508a104a3a0b5d96b76495c709785c1d11610908e63481ee667","affectsGlobalScope":true,"impliedFormat":1},{"version":"ac9538681b19688c8eae65811b329d3744af679e0bdfa5d842d0e32524c73e1c","affectsGlobalScope":true,"impliedFormat":1},{"version":"0a969edff4bd52585473d24995c5ef223f6652d6ef46193309b3921d65dd4376","affectsGlobalScope":true,"impliedFormat":1},{"version":"9e9fbd7030c440b33d021da145d3232984c8bb7916f277e8ffd3dc2e3eae2bdb","affectsGlobalScope":true,"impliedFormat":1},{"version":"811ec78f7fefcabbda4bfa93b3eb67d9ae166ef95f9bff989d964061cbf81a0c","affectsGlobalScope":true,"impliedFormat":1},{"version":"717937616a17072082152a2ef351cb51f98802fb4b2fdabd32399843875974ca","affectsGlobalScope":true,"impliedFormat":1},{"version":"d7e7d9b7b50e5f22c915b525acc5a49a7a6584cf8f62d0569e557c5cfc4b2ac2","affectsGlobalScope":true,"impliedFormat":1},{"version":"71c37f4c9543f31dfced6c7840e068c5a5aacb7b89111a4364b1d5276b852557","affectsGlobalScope":true,"impliedFormat":1},{"version":"576711e016cf4f1804676043e6a0a5414252560eb57de9faceee34d79798c850","affectsGlobalScope":true,"impliedFormat":1},{"version":"89c1b1281ba7b8a96efc676b11b264de7a8374c5ea1e6617f11880a13fc56dc6","affectsGlobalScope":true,"impliedFormat":1},{"version":"74f7fa2d027d5b33eb0471c8e82a6c87216223181ec31247c357a3e8e2fddc5b","affectsGlobalScope":true,"impliedFormat":1},{"version":"d6d7ae4d1f1f3772e2a3cde568ed08991a8ae34a080ff1151af28b7f798e22ca","affectsGlobalScope":true,"impliedFormat":1},{"version":"063600664504610fe3e99b717a1223f8b1900087fab0b4cad1496a114744f8df","affectsGlobalScope":true,"impliedFormat":1},{"version":"934019d7e3c81950f9a8426d093458b65d5aff2c7c1511233c0fd5b941e608ab","affectsGlobalScope":true,"impliedFormat":1},{"version":"52ada8e0b6e0482b728070b7639ee42e83a9b1c22d205992756fe020fd9f4a47","affectsGlobalScope":true,"impliedFormat":1},{"version":"3bdefe1bfd4d6dee0e26f928f93ccc128f1b64d5d501ff4a8cf3c6371200e5e6","affectsGlobalScope":true,"impliedFormat":1},{"version":"59fb2c069260b4ba00b5643b907ef5d5341b167e7d1dbf58dfd895658bda2867","affectsGlobalScope":true,"impliedFormat":1},{"version":"639e512c0dfc3fad96a84caad71b8834d66329a1f28dc95e3946c9b58176c73a","affectsGlobalScope":true,"impliedFormat":1},{"version":"368af93f74c9c932edd84c58883e736c9e3d53cec1fe24c0b0ff451f529ceab1","affectsGlobalScope":true,"impliedFormat":1},{"version":"8e7f8264d0fb4c5339605a15daadb037bf238c10b654bb3eee14208f860a32ea","affectsGlobalScope":true,"impliedFormat":1},{"version":"782dec38049b92d4e85c1585fbea5474a219c6984a35b004963b00beb1aab538","affectsGlobalScope":true,"impliedFormat":1},{"version":"fef51c61e56ccb972628e5ca09411e6c72d07e0a848c7805ca15cb7c3cdab8fa","signature":"96a00686e4847504e1bbe918ecece071d56afa533b6fc54be2565af42d3d5b44"},{"version":"37e3c3d08ea92743ed2f699f456cb438ab457eca0ac201f58cf2f6173f07ddf2","signature":"97bfadb408f0a86222dff15dcaf8feb467887298f0c9794c2d84ea3c0fb3c701"},{"version":"56039c7513b2b29b85c8d83067528b1a8094764a285848887eb7ba842018d20d","signature":"edd3c7122eae4403430f65810a404a614996e003c8c35f1f3c175230c3bcaff1"},{"version":"70521b6ab0dcba37539e5303104f29b721bfb2940b2776da4cc818c07e1fefc1","affectsGlobalScope":true,"impliedFormat":1},{"version":"ab41ef1f2cdafb8df48be20cd969d875602483859dc194e9c97c8a576892c052","affectsGlobalScope":true,"impliedFormat":1},{"version":"d153a11543fd884b596587ccd97aebbeed950b26933ee000f94009f1ab142848","affectsGlobalScope":true,"impliedFormat":1},{"version":"21d819c173c0cf7cc3ce57c3276e77fd9a8a01d35a06ad87158781515c9a438a","impliedFormat":1},{"version":"98cffbf06d6bab333473c70a893770dbe990783904002c4f1a960447b4b53dca","affectsGlobalScope":true,"impliedFormat":1},{"version":"ba481bca06f37d3f2c137ce343c7d5937029b2468f8e26111f3c9d9963d6568d","affectsGlobalScope":true,"impliedFormat":1},{"version":"6d9ef24f9a22a88e3e9b3b3d8c40ab1ddb0853f1bfbd5c843c37800138437b61","affectsGlobalScope":true,"impliedFormat":1},{"version":"1db0b7dca579049ca4193d034d835f6bfe73096c73663e5ef9a0b5779939f3d0","affectsGlobalScope":true,"impliedFormat":1},{"version":"9798340ffb0d067d69b1ae5b32faa17ab31b82466a3fc00d8f2f2df0c8554aaa","affectsGlobalScope":true,"impliedFormat":1},{"version":"f26b11d8d8e4b8028f1c7d618b22274c892e4b0ef5b3678a8ccbad85419aef43","affectsGlobalScope":true,"impliedFormat":1},{"version":"8e9c23ba78aabc2e0a27033f18737a6df754067731e69dc5f52823957d60a4b6","impliedFormat":1},{"version":"5929864ce17fba74232584d90cb721a89b7ad277220627cc97054ba15a98ea8f","impliedFormat":1},{"version":"763fe0f42b3d79b440a9b6e51e9ba3f3f91352469c1e4b3b67bfa4ff6352f3f4","impliedFormat":1},{"version":"25c8056edf4314820382a5fdb4bb7816999acdcb929c8f75e3f39473b87e85bc","impliedFormat":1},{"version":"c464d66b20788266e5353b48dc4aa6bc0dc4a707276df1e7152ab0c9ae21fad8","impliedFormat":1},{"version":"78d0d27c130d35c60b5e5566c9f1e5be77caf39804636bc1a40133919a949f21","impliedFormat":1},{"version":"c6fd2c5a395f2432786c9cb8deb870b9b0e8ff7e22c029954fabdd692bff6195","impliedFormat":1},{"version":"1d6e127068ea8e104a912e42fc0a110e2aa5a66a356a917a163e8cf9a65e4a75","impliedFormat":1},{"version":"5ded6427296cdf3b9542de4471d2aa8d3983671d4cac0f4bf9c637208d1ced43","impliedFormat":1},{"version":"7f182617db458e98fc18dfb272d40aa2fff3a353c44a89b2c0ccb3937709bfb5","impliedFormat":1},{"version":"cadc8aced301244057c4e7e73fbcae534b0f5b12a37b150d80e5a45aa4bebcbd","impliedFormat":1},{"version":"385aab901643aa54e1c36f5ef3107913b10d1b5bb8cbcd933d4263b80a0d7f20","impliedFormat":1},{"version":"9670d44354bab9d9982eca21945686b5c24a3f893db73c0dae0fd74217a4c219","impliedFormat":1},{"version":"0b8a9268adaf4da35e7fa830c8981cfa22adbbe5b3f6f5ab91f6658899e657a7","impliedFormat":1},{"version":"11396ed8a44c02ab9798b7dca436009f866e8dae3c9c25e8c1fbc396880bf1bb","impliedFormat":1},{"version":"ba7bc87d01492633cb5a0e5da8a4a42a1c86270e7b3d2dea5d156828a84e4882","impliedFormat":1},{"version":"4893a895ea92c85345017a04ed427cbd6a1710453338df26881a6019432febdd","impliedFormat":1},{"version":"c21dc52e277bcfc75fac0436ccb75c204f9e1b3fa5e12729670910639f27343e","impliedFormat":1},{"version":"13f6f39e12b1518c6650bbb220c8985999020fe0f21d818e28f512b7771d00f9","impliedFormat":1},{"version":"9b5369969f6e7175740bf51223112ff209f94ba43ecd3bb09eefff9fd675624a","impliedFormat":1},{"version":"4fe9e626e7164748e8769bbf74b538e09607f07ed17c2f20af8d680ee49fc1da","impliedFormat":1},{"version":"24515859bc0b836719105bb6cc3d68255042a9f02a6022b3187948b204946bd2","impliedFormat":1},{"version":"ea0148f897b45a76544ae179784c95af1bd6721b8610af9ffa467a518a086a43","impliedFormat":1},{"version":"24c6a117721e606c9984335f71711877293a9651e44f59f3d21c1ea0856f9cc9","impliedFormat":1},{"version":"dd3273ead9fbde62a72949c97dbec2247ea08e0c6952e701a483d74ef92d6a17","impliedFormat":1},{"version":"405822be75ad3e4d162e07439bac80c6bcc6dbae1929e179cf467ec0b9ee4e2e","impliedFormat":1},{"version":"0db18c6e78ea846316c012478888f33c11ffadab9efd1cc8bcc12daded7a60b6","impliedFormat":1},{"version":"e61be3f894b41b7baa1fbd6a66893f2579bfad01d208b4ff61daef21493ef0a8","impliedFormat":1},{"version":"bd0532fd6556073727d28da0edfd1736417a3f9f394877b6d5ef6ad88fba1d1a","impliedFormat":1},{"version":"89167d696a849fce5ca508032aabfe901c0868f833a8625d5a9c6e861ef935d2","impliedFormat":1},{"version":"615ba88d0128ed16bf83ef8ccbb6aff05c3ee2db1cc0f89ab50a4939bfc1943f","impliedFormat":1},{"version":"a4d551dbf8746780194d550c88f26cf937caf8d56f102969a110cfaed4b06656","impliedFormat":1},{"version":"8bd86b8e8f6a6aa6c49b71e14c4ffe1211a0e97c80f08d2c8cc98838006e4b88","impliedFormat":1},{"version":"317e63deeb21ac07f3992f5b50cdca8338f10acd4fbb7257ebf56735bf52ab00","impliedFormat":1},{"version":"4732aec92b20fb28c5fe9ad99521fb59974289ed1e45aecb282616202184064f","impliedFormat":1},{"version":"2e85db9e6fd73cfa3d7f28e0ab6b55417ea18931423bd47b409a96e4a169e8e6","impliedFormat":1},{"version":"c46e079fe54c76f95c67fb89081b3e399da2c7d109e7dca8e4b58d83e332e605","impliedFormat":1},{"version":"bf67d53d168abc1298888693338cb82854bdb2e69ef83f8a0092093c2d562107","impliedFormat":1},{"version":"b52476feb4a0cbcb25e5931b930fc73cb6643fb1a5060bf8a3dda0eeae5b4b68","affectsGlobalScope":true,"impliedFormat":1},{"version":"e2677634fe27e87348825bb041651e22d50a613e2fdf6a4a3ade971d71bac37e","impliedFormat":1},{"version":"7394959e5a741b185456e1ef5d64599c36c60a323207450991e7a42e08911419","impliedFormat":1},{"version":"8c0bcd6c6b67b4b503c11e91a1fb91522ed585900eab2ab1f61bba7d7caa9d6f","impliedFormat":1},{"version":"8cd19276b6590b3ebbeeb030ac271871b9ed0afc3074ac88a94ed2449174b776","affectsGlobalScope":true,"impliedFormat":1},{"version":"696eb8d28f5949b87d894b26dc97318ef944c794a9a4e4f62360cd1d1958014b","impliedFormat":1},{"version":"3f8fa3061bd7402970b399300880d55257953ee6d3cd408722cb9ac20126460c","impliedFormat":1},{"version":"35ec8b6760fd7138bbf5809b84551e31028fb2ba7b6dc91d95d098bf212ca8b4","affectsGlobalScope":true,"impliedFormat":1},{"version":"5524481e56c48ff486f42926778c0a3cce1cc85dc46683b92b1271865bcf015a","impliedFormat":1},{"version":"68bd56c92c2bd7d2339457eb84d63e7de3bd56a69b25f3576e1568d21a162398","affectsGlobalScope":true,"impliedFormat":1},{"version":"3e93b123f7c2944969d291b35fed2af79a6e9e27fdd5faa99748a51c07c02d28","impliedFormat":1},{"version":"9d19808c8c291a9010a6c788e8532a2da70f811adb431c97520803e0ec649991","impliedFormat":1},{"version":"87aad3dd9752067dc875cfaa466fc44246451c0c560b820796bdd528e29bef40","impliedFormat":1},{"version":"4aacb0dd020eeaef65426153686cc639a78ec2885dc72ad220be1d25f1a439df","impliedFormat":1},{"version":"f0bd7e6d931657b59605c44112eaf8b980ba7f957a5051ed21cb93d978cf2f45","impliedFormat":1},{"version":"8db0ae9cb14d9955b14c214f34dae1b9ef2baee2fe4ce794a4cd3ac2531e3255","affectsGlobalScope":true,"impliedFormat":1},{"version":"15fc6f7512c86810273af28f224251a5a879e4261b4d4c7e532abfbfc3983134","impliedFormat":1},{"version":"58adba1a8ab2d10b54dc1dced4e41f4e7c9772cbbac40939c0dc8ce2cdb1d442","impliedFormat":1},{"version":"641942a78f9063caa5d6b777c99304b7d1dc7328076038c6d94d8a0b81fc95c1","impliedFormat":1},{"version":"2de7636e6fbb9e54a61a38bcb7505b94ec5be61197fe9e840cff629ca920c4bc","impliedFormat":1},{"version":"855cd5f7eb396f5f1ab1bc0f8580339bff77b68a770f84c6b254e319bbfd1ac7","impliedFormat":1},{"version":"5650cf3dace09e7c25d384e3e6b818b938f68f4e8de96f52d9c5a1b3db068e86","impliedFormat":1},{"version":"1354ca5c38bd3fd3836a68e0f7c9f91f172582ba30ab15bb8c075891b91502b7","affectsGlobalScope":true,"impliedFormat":1},{"version":"7e20d899c28ca26a2a7afc98beaa69e63ff7fba0a8bc47b4e3bf3ede5e09e424","impliedFormat":1},{"version":"2d2fcaab481b31a5882065c7951255703ddbe1c0e507af56ea42d79ac3911201","impliedFormat":1},{"version":"a192fe8ec33f75edbc8d8f3ed79f768dfae11ff5735e7fe52bfa69956e46d78d","impliedFormat":1},{"version":"ca867399f7db82df981d6915bcbb2d81131d7d1ef683bc782b59f71dda59bc85","affectsGlobalScope":true,"impliedFormat":1},{"version":"372413016d17d804e1d139418aca0c68e47a83fb6669490857f4b318de8cccb3","affectsGlobalScope":true,"impliedFormat":1},{"version":"9e043a1bc8fbf2a255bccf9bf27e0f1caf916c3b0518ea34aa72357c0afd42ec","impliedFormat":1},{"version":"b4f70ec656a11d570e1a9edce07d118cd58d9760239e2ece99306ee9dfe61d02","impliedFormat":1},{"version":"3bc2f1e2c95c04048212c569ed38e338873f6a8593930cf5a7ef24ffb38fc3b6","impliedFormat":1},{"version":"6e70e9570e98aae2b825b533aa6292b6abd542e8d9f6e9475e88e1d7ba17c866","impliedFormat":1},{"version":"f9d9d753d430ed050dc1bf2667a1bab711ccbb1c1507183d794cc195a5b085cc","impliedFormat":1},{"version":"9eece5e586312581ccd106d4853e861aaaa1a39f8e3ea672b8c3847eedd12f6e","impliedFormat":1},{"version":"085f552d005479e2e6a7311cdbbe5d8c55c497b4d19274285df161ee9684cd9c","impliedFormat":1},{"version":"37ba7b45141a45ce6e80e66f2a96c8a5ab1bcef0fc2d0f56bb58df96ec67e972","impliedFormat":1},{"version":"45650f47bfb376c8a8ed39d4bcda5902ab899a3150029684ee4c10676d9fbaee","impliedFormat":1},{"version":"007faacc9268357caa21d24169f3f3f2497af3e9241308df2d89f6e6d9bb3f2e","affectsGlobalScope":true,"impliedFormat":1},{"version":"74cf591a0f63db318651e0e04cb55f8791385f86e987a67fd4d2eaab8191f730","impliedFormat":1},{"version":"5eab9b3dc9b34f185417342436ec3f106898da5f4801992d8ff38ab3aff346b5","impliedFormat":1},{"version":"12ed4559eba17cd977aa0db658d25c4047067444b51acfdcbf38470630642b23","affectsGlobalScope":true,"impliedFormat":1},{"version":"f3ffabc95802521e1e4bcba4c88d8615176dc6e09111d920c7a213bdda6e1d65","impliedFormat":1},{"version":"809821b8a065e3234a55b3a9d7846231ed18d66dd749f2494c66288d890daf7f","impliedFormat":1},{"version":"ae56f65caf3be91108707bd8dfbccc2a57a91feb5daabf7165a06a945545ed26","impliedFormat":1},{"version":"a136d5de521da20f31631a0a96bf712370779d1c05b7015d7019a9b2a0446ca9","impliedFormat":1},{"version":"c3b41e74b9a84b88b1dca61ec39eee25c0dbc8e7d519ba11bb070918cfacf656","affectsGlobalScope":true,"impliedFormat":1},{"version":"4737a9dc24d0e68b734e6cfbcea0c15a2cfafeb493485e27905f7856988c6b29","affectsGlobalScope":true,"impliedFormat":1},{"version":"36d8d3e7506b631c9582c251a2c0b8a28855af3f76719b12b534c6edf952748d","impliedFormat":1},{"version":"1ca69210cc42729e7ca97d3a9ad48f2e9cb0042bada4075b588ae5387debd318","impliedFormat":1},{"version":"f5ebe66baaf7c552cfa59d75f2bfba679f329204847db3cec385acda245e574e","impliedFormat":1},{"version":"ed59add13139f84da271cafd32e2171876b0a0af2f798d0c663e8eeb867732cf","affectsGlobalScope":true,"impliedFormat":1},{"version":"b7c5e2ea4a9749097c347454805e933844ed207b6eefec6b7cfd418b5f5f7b28","impliedFormat":1},{"version":"b1810689b76fd473bd12cc9ee219f8e62f54a7d08019a235d07424afbf074d25","impliedFormat":1}],"root":[[48,50]],"options":{"alwaysStrict":true,"composite":true,"declaration":true,"declarationMap":true,"esModuleInterop":true,"exactOptionalPropertyTypes":true,"module":99,"noImplicitAny":true,"noImplicitThis":true,"outDir":"./","skipLibCheck":true,"strict":true,"strictBindCallApply":true,"strictFunctionTypes":true,"strictNullChecks":true,"strictPropertyInitialization":true,"target":99,"useUnknownInCatchVariables":true},"referencedMap":[[100,1],[101,1],[102,2],[56,3],[103,4],[104,5],[105,6],[51,7],[54,8],[52,7],[53,7],[106,9],[107,10],[108,11],[109,12],[110,13],[111,14],[112,14],[113,15],[114,16],[115,17],[116,18],[57,7],[55,7],[117,19],[118,20],[119,21],[151,22],[120,23],[121,24],[122,25],[123,26],[124,27],[125,28],[126,29],[127,30],[128,31],[129,32],[130,32],[131,33],[132,7],[133,34],[135,35],[134,36],[136,37],[137,38],[138,39],[139,40],[140,41],[141,42],[142,43],[143,44],[144,45],[145,46],[146,47],[147,48],[148,49],[58,7],[59,7],[60,7],[99,50],[149,51],[150,52],[61,7],[46,7],[47,7],[8,7],[9,7],[11,7],[10,7],[2,7],[12,7],[13,7],[14,7],[15,7],[16,7],[17,7],[18,7],[19,7],[3,7],[20,7],[21,7],[4,7],[22,7],[26,7],[23,7],[24,7],[25,7],[27,7],[28,7],[29,7],[5,7],[30,7],[31,7],[32,7],[33,7],[6,7],[37,7],[34,7],[35,7],[36,7],[38,7],[7,7],[39,7],[44,7],[45,7],[40,7],[41,7],[42,7],[43,7],[1,7],[77,53],[87,54],[76,53],[97,55],[68,56],[67,57],[96,58],[90,59],[95,60],[70,61],[84,62],[69,63],[93,64],[65,65],[64,58],[94,66],[66,67],[71,68],[72,7],[75,68],[62,7],[98,69],[88,70],[79,71],[80,72],[82,73],[78,74],[81,75],[91,58],[73,76],[74,77],[83,78],[63,79],[86,70],[85,68],[89,7],[92,80],[48,7],[49,81],[50,82]],"latestChangedDtsFile":"./index.d.ts","version":"5.9.3"}
@@ -0,0 +1,67 @@
1
+ /**
2
+ * Represents all known Cache-Control directives.
3
+ *
4
+ * https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Cache-Control
5
+ */
6
+ export type CacheControl = {
7
+ /**
8
+ * The maximum amount of time (in seconds) a resource is considered fresh.
9
+ * Example: `max-age=3600` (1 hour)
10
+ */
11
+ readonly maxAge?: number;
12
+ /**
13
+ * Requires the resource to be revalidated with the origin server before serving it from the cache.
14
+ * Example: `no-cache`
15
+ */
16
+ readonly noCache?: boolean;
17
+ /**
18
+ * Prevents the resource from being cached by any mechanism.
19
+ * Example: `no-store`
20
+ */
21
+ readonly noStore?: boolean;
22
+ /**
23
+ * Ensures that stale responses cannot be used without successful revalidation with the origin server.
24
+ * Example: `must-revalidate`
25
+ */
26
+ readonly mustRevalidate?: boolean;
27
+ /**
28
+ * Indicates the resource is cacheable by both shared and private caches.
29
+ * Example: `public`
30
+ */
31
+ readonly public?: boolean;
32
+ /**
33
+ * Indicates the resource is cacheable only by the user's browser or private caches, not shared caches.
34
+ * Example: `private`
35
+ */
36
+ readonly private?: boolean;
37
+ /**
38
+ * Indicates that the resource will not change, so it does not need to be revalidated.
39
+ * Example: `immutable`
40
+ */
41
+ readonly immutable?: boolean;
42
+ /**
43
+ * Allows serving stale responses for the specified duration (in seconds) while asynchronously revalidating the
44
+ * cache.
45
+ * Example: `stale-while-revalidate=60`
46
+ */
47
+ readonly staleWhileRevalidate?: number;
48
+ /**
49
+ * Allows serving stale responses (in seconds) if the origin server is unavailable or returns an error.
50
+ * Example: `stale-if-error=86400` (1 day)
51
+ */
52
+ readonly staleIfError?: number;
53
+ /**
54
+ * Indicates the client only wants a response from the cache and will not make a network request.
55
+ * Example: `only-if-cached`
56
+ */
57
+ readonly onlyIfCached?: boolean;
58
+ };
59
+ /**
60
+ * Parses a Cache-Control header string into a structured object.
61
+ * Handles known directives with optional numeric values.
62
+ *
63
+ * @param str - The Cache-Control header string to parse.
64
+ * @returns A CacheControl object representing the parsed directives.
65
+ */
66
+ export declare function parseCacheControl(str: string | null | undefined): CacheControl;
67
+ //# sourceMappingURL=CacheControl.d.ts.map