@types/serviceworker 0.0.204 → 0.0.205
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/README.md +1 -1
- package/index.d.ts +122 -7
- package/package.json +1 -1
- package/ts5.5/index.d.ts +113 -7
- package/ts5.5/iterable.d.ts +9 -0
- package/ts5.6/index.d.ts +113 -7
- package/ts5.6/iterable.d.ts +9 -0
- package/ts5.9/index.d.ts +113 -7
- package/ts5.9/iterable.d.ts +9 -0
package/README.md
CHANGED
|
@@ -30,4 +30,4 @@ This project does not respect semantic versioning as almost every change could p
|
|
|
30
30
|
|
|
31
31
|
## Deploy Metadata
|
|
32
32
|
|
|
33
|
-
You can read what changed in version 0.0.
|
|
33
|
+
You can read what changed in version 0.0.205 at https://github.com/microsoft/TypeScript-DOM-lib-generator/releases/tag/%40types%2Fserviceworker%400.0.205.
|
package/index.d.ts
CHANGED
|
@@ -536,8 +536,10 @@ interface GPURenderPipelineDescriptor extends GPUPipelineDescriptorBase {
|
|
|
536
536
|
}
|
|
537
537
|
|
|
538
538
|
interface GPURequestAdapterOptions {
|
|
539
|
+
featureLevel?: string;
|
|
539
540
|
forceFallbackAdapter?: boolean;
|
|
540
541
|
powerPreference?: GPUPowerPreference;
|
|
542
|
+
xrCompatible?: boolean;
|
|
541
543
|
}
|
|
542
544
|
|
|
543
545
|
interface GPUSamplerBindingLayout {
|
|
@@ -557,8 +559,14 @@ interface GPUSamplerDescriptor extends GPUObjectDescriptorBase {
|
|
|
557
559
|
mipmapFilter?: GPUMipmapFilterMode;
|
|
558
560
|
}
|
|
559
561
|
|
|
562
|
+
interface GPUShaderModuleCompilationHint {
|
|
563
|
+
entryPoint: string;
|
|
564
|
+
layout?: GPUPipelineLayout | GPUAutoLayoutMode;
|
|
565
|
+
}
|
|
566
|
+
|
|
560
567
|
interface GPUShaderModuleDescriptor extends GPUObjectDescriptorBase {
|
|
561
568
|
code: string;
|
|
569
|
+
compilationHints?: GPUShaderModuleCompilationHint[];
|
|
562
570
|
}
|
|
563
571
|
|
|
564
572
|
interface GPUStencilFaceState {
|
|
@@ -615,6 +623,7 @@ interface GPUTextureViewDescriptor extends GPUObjectDescriptorBase {
|
|
|
615
623
|
dimension?: GPUTextureViewDimension;
|
|
616
624
|
format?: GPUTextureFormat;
|
|
617
625
|
mipLevelCount?: GPUIntegerCoordinate;
|
|
626
|
+
swizzle?: string;
|
|
618
627
|
usage?: GPUTextureUsageFlags;
|
|
619
628
|
}
|
|
620
629
|
|
|
@@ -663,6 +672,12 @@ interface IDBDatabaseInfo {
|
|
|
663
672
|
version?: number;
|
|
664
673
|
}
|
|
665
674
|
|
|
675
|
+
interface IDBGetAllOptions {
|
|
676
|
+
count?: number;
|
|
677
|
+
direction?: IDBCursorDirection;
|
|
678
|
+
query?: any;
|
|
679
|
+
}
|
|
680
|
+
|
|
666
681
|
interface IDBIndexParameters {
|
|
667
682
|
multiEntry?: boolean;
|
|
668
683
|
unique?: boolean;
|
|
@@ -878,7 +893,12 @@ interface PushSubscriptionChangeEventInit extends ExtendableEventInit {
|
|
|
878
893
|
interface PushSubscriptionJSON {
|
|
879
894
|
endpoint?: string;
|
|
880
895
|
expirationTime?: EpochTimeStamp | null;
|
|
881
|
-
keys?:
|
|
896
|
+
keys?: PushSubscriptionKeys;
|
|
897
|
+
}
|
|
898
|
+
|
|
899
|
+
interface PushSubscriptionKeys {
|
|
900
|
+
auth?: string;
|
|
901
|
+
p256dh?: string;
|
|
882
902
|
}
|
|
883
903
|
|
|
884
904
|
interface PushSubscriptionOptionsInit {
|
|
@@ -1000,6 +1020,25 @@ interface ResponseInit {
|
|
|
1000
1020
|
statusText?: string;
|
|
1001
1021
|
}
|
|
1002
1022
|
|
|
1023
|
+
interface RouterCondition {
|
|
1024
|
+
not?: RouterCondition;
|
|
1025
|
+
or?: RouterCondition[];
|
|
1026
|
+
requestDestination?: RequestDestination;
|
|
1027
|
+
requestMethod?: string;
|
|
1028
|
+
requestMode?: RequestMode;
|
|
1029
|
+
runningStatus?: RunningStatus;
|
|
1030
|
+
urlPattern?: URLPatternCompatible;
|
|
1031
|
+
}
|
|
1032
|
+
|
|
1033
|
+
interface RouterRule {
|
|
1034
|
+
condition: RouterCondition;
|
|
1035
|
+
source: RouterSource;
|
|
1036
|
+
}
|
|
1037
|
+
|
|
1038
|
+
interface RouterSourceDict {
|
|
1039
|
+
cacheName?: string;
|
|
1040
|
+
}
|
|
1041
|
+
|
|
1003
1042
|
interface RsaHashedImportParams extends Algorithm {
|
|
1004
1043
|
hash: HashAlgorithmIdentifier;
|
|
1005
1044
|
}
|
|
@@ -6168,6 +6207,12 @@ interface IDBIndex {
|
|
|
6168
6207
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/IDBIndex/getAllKeys)
|
|
6169
6208
|
*/
|
|
6170
6209
|
getAllKeys(queryOrOptions?: IDBValidKey | IDBKeyRange | null, count?: number): IDBRequest<IDBValidKey[]>;
|
|
6210
|
+
/**
|
|
6211
|
+
* The **`getAllRecords()`** method of the IDBIndex interface retrieves all records (including index keys, primary keys, and values) from the index.
|
|
6212
|
+
*
|
|
6213
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/IDBIndex/getAllRecords)
|
|
6214
|
+
*/
|
|
6215
|
+
getAllRecords(options?: IDBGetAllOptions): IDBRequest;
|
|
6171
6216
|
/**
|
|
6172
6217
|
* The **`getKey()`** method of the IDBIndex interface returns an IDBRequest object, and, in a separate thread, finds either the primary key that corresponds to the given key in this index or the first corresponding primary key, if key is set to an IDBKeyRange.
|
|
6173
6218
|
*
|
|
@@ -6350,6 +6395,12 @@ interface IDBObjectStore {
|
|
|
6350
6395
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/IDBObjectStore/getAllKeys)
|
|
6351
6396
|
*/
|
|
6352
6397
|
getAllKeys(queryOrOptions?: IDBValidKey | IDBKeyRange | null, count?: number): IDBRequest<IDBValidKey[]>;
|
|
6398
|
+
/**
|
|
6399
|
+
* The **`getAllRecords()`** method of the IDBObjectStore interface retrieves all records (including primary keys and values) from the object store.
|
|
6400
|
+
*
|
|
6401
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/IDBObjectStore/getAllRecords)
|
|
6402
|
+
*/
|
|
6403
|
+
getAllRecords(options?: IDBGetAllOptions): IDBRequest;
|
|
6353
6404
|
/**
|
|
6354
6405
|
* The **`getKey()`** method of the IDBObjectStore interface returns an IDBRequest object, and, in a separate thread, returns the key selected by the specified query. This is for retrieving specific records from an object store.
|
|
6355
6406
|
*
|
|
@@ -6413,6 +6464,18 @@ declare var IDBOpenDBRequest: {
|
|
|
6413
6464
|
new(): IDBOpenDBRequest;
|
|
6414
6465
|
};
|
|
6415
6466
|
|
|
6467
|
+
/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/IDBRecord) */
|
|
6468
|
+
interface IDBRecord {
|
|
6469
|
+
readonly key: any;
|
|
6470
|
+
readonly primaryKey: any;
|
|
6471
|
+
readonly value: any;
|
|
6472
|
+
}
|
|
6473
|
+
|
|
6474
|
+
declare var IDBRecord: {
|
|
6475
|
+
prototype: IDBRecord;
|
|
6476
|
+
new(): IDBRecord;
|
|
6477
|
+
};
|
|
6478
|
+
|
|
6416
6479
|
interface IDBRequestEventMap {
|
|
6417
6480
|
"error": Event;
|
|
6418
6481
|
"success": Event;
|
|
@@ -6664,6 +6727,25 @@ interface ImportMeta {
|
|
|
6664
6727
|
resolve(specifier: string): string;
|
|
6665
6728
|
}
|
|
6666
6729
|
|
|
6730
|
+
/**
|
|
6731
|
+
* The parameter passed into an install event handler function, the **`InstallEvent`** interface represents an install action that is dispatched on the ServiceWorkerGlobalScope of a ServiceWorker. As a child of ExtendableEvent, it ensures that functional events such as FetchEvent are not dispatched during installation.
|
|
6732
|
+
*
|
|
6733
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/InstallEvent)
|
|
6734
|
+
*/
|
|
6735
|
+
interface InstallEvent extends ExtendableEvent {
|
|
6736
|
+
/**
|
|
6737
|
+
* The **`addRoutes()`** method of the InstallEvent interface specifies one or more static routes, which define rules for fetching specified resources that will be used even before service worker startup. This allows you to, for example, bypass a service worker in cases where you always want to fetch a resource from the network or a browser Cache, and avoids the performance overhead of unnecessary service worker cycles.
|
|
6738
|
+
*
|
|
6739
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/InstallEvent/addRoutes)
|
|
6740
|
+
*/
|
|
6741
|
+
addRoutes(rules: RouterRule | RouterRule[]): Promise<void>;
|
|
6742
|
+
}
|
|
6743
|
+
|
|
6744
|
+
declare var InstallEvent: {
|
|
6745
|
+
prototype: InstallEvent;
|
|
6746
|
+
new(type: string, eventInitDict?: ExtendableEventInit): InstallEvent;
|
|
6747
|
+
};
|
|
6748
|
+
|
|
6667
6749
|
/**
|
|
6668
6750
|
* The **`KHR_parallel_shader_compile`** extension is part of the WebGL API and enables a non-blocking poll operation, so that compile/link status availability (COMPLETION_STATUS_KHR) can be queried without potentially incurring stalls. In other words you can check the status of your shaders compiling without blocking the runtime.
|
|
6669
6751
|
*
|
|
@@ -7425,12 +7507,18 @@ interface Performance extends EventTarget {
|
|
|
7425
7507
|
*
|
|
7426
7508
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/Performance/getEntriesByName)
|
|
7427
7509
|
*/
|
|
7510
|
+
getEntriesByName(name: string, type: "mark"): PerformanceMark[];
|
|
7511
|
+
getEntriesByName(name: string, type: "measure"): PerformanceMeasure[];
|
|
7512
|
+
getEntriesByName(name: string, type: "resource"): PerformanceResourceTiming[];
|
|
7428
7513
|
getEntriesByName(name: string, type?: string): PerformanceEntryList;
|
|
7429
7514
|
/**
|
|
7430
7515
|
* The **`getEntriesByType()`** method returns an array of PerformanceEntry objects currently present in the performance timeline for a given type.
|
|
7431
7516
|
*
|
|
7432
7517
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/Performance/getEntriesByType)
|
|
7433
7518
|
*/
|
|
7519
|
+
getEntriesByType(type: "mark"): PerformanceMark[];
|
|
7520
|
+
getEntriesByType(type: "measure"): PerformanceMeasure[];
|
|
7521
|
+
getEntriesByType(type: "resource"): PerformanceResourceTiming[];
|
|
7434
7522
|
getEntriesByType(type: string): PerformanceEntryList;
|
|
7435
7523
|
/**
|
|
7436
7524
|
* The **`mark()`** method creates a named PerformanceMark object representing a high resolution timestamp marker in the browser's performance timeline.
|
|
@@ -7608,12 +7696,18 @@ interface PerformanceObserverEntryList {
|
|
|
7608
7696
|
*
|
|
7609
7697
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/PerformanceObserverEntryList/getEntriesByName)
|
|
7610
7698
|
*/
|
|
7699
|
+
getEntriesByName(name: string, type: "mark"): PerformanceMark[];
|
|
7700
|
+
getEntriesByName(name: string, type: "measure"): PerformanceMeasure[];
|
|
7701
|
+
getEntriesByName(name: string, type: "resource"): PerformanceResourceTiming[];
|
|
7611
7702
|
getEntriesByName(name: string, type?: string): PerformanceEntryList;
|
|
7612
7703
|
/**
|
|
7613
7704
|
* The **`getEntriesByType()`** method of the PerformanceObserverEntryList returns a list of explicitly observed performance entry objects for a given performance entry type. The list's members are determined by the set of entry types specified in the call to the observe() method. The list is available in the observer's callback function (as the first parameter in the callback).
|
|
7614
7705
|
*
|
|
7615
7706
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/PerformanceObserverEntryList/getEntriesByType)
|
|
7616
7707
|
*/
|
|
7708
|
+
getEntriesByType(type: "mark"): PerformanceMark[];
|
|
7709
|
+
getEntriesByType(type: "measure"): PerformanceMeasure[];
|
|
7710
|
+
getEntriesByType(type: "resource"): PerformanceResourceTiming[];
|
|
7617
7711
|
getEntriesByType(type: string): PerformanceEntryList;
|
|
7618
7712
|
}
|
|
7619
7713
|
|
|
@@ -7760,6 +7854,8 @@ interface PerformanceResourceTiming extends PerformanceEntry {
|
|
|
7760
7854
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/PerformanceResourceTiming/transferSize)
|
|
7761
7855
|
*/
|
|
7762
7856
|
readonly transferSize: number;
|
|
7857
|
+
readonly workerCacheLookupStart: DOMHighResTimeStamp;
|
|
7858
|
+
readonly workerRouterEvaluationStart: DOMHighResTimeStamp;
|
|
7763
7859
|
/**
|
|
7764
7860
|
* The **`workerStart`** read-only property of the PerformanceResourceTiming interface returns a DOMHighResTimeStamp immediately before dispatching the FetchEvent if a Service Worker thread is already running, or immediately before starting the Service Worker thread if it is not already running. If the resource is not intercepted by a Service Worker the property will always return 0.
|
|
7765
7861
|
*
|
|
@@ -8216,6 +8312,12 @@ declare var ReadableStream: {
|
|
|
8216
8312
|
new(underlyingSource: UnderlyingByteSource, strategy?: { highWaterMark?: number }): ReadableStream<Uint8Array<ArrayBuffer>>;
|
|
8217
8313
|
new<R = any>(underlyingSource: UnderlyingDefaultSource<R>, strategy?: QueuingStrategy<R>): ReadableStream<R>;
|
|
8218
8314
|
new<R = any>(underlyingSource?: UnderlyingSource<R>, strategy?: QueuingStrategy<R>): ReadableStream<R>;
|
|
8315
|
+
/**
|
|
8316
|
+
* The **`ReadableStream.from()`** static method returns a ReadableStream from a provided iterable or async iterable object.
|
|
8317
|
+
*
|
|
8318
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableStream/from_static)
|
|
8319
|
+
*/
|
|
8320
|
+
from(asyncIterable: AsyncIterable<any> | Iterable<any>): ReadableStream;
|
|
8219
8321
|
};
|
|
8220
8322
|
|
|
8221
8323
|
/**
|
|
@@ -8561,7 +8663,7 @@ interface Scheduler {
|
|
|
8561
8663
|
*
|
|
8562
8664
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/Scheduler/postTask)
|
|
8563
8665
|
*/
|
|
8564
|
-
postTask(callback: SchedulerPostTaskCallback
|
|
8666
|
+
postTask<T = any>(callback: SchedulerPostTaskCallback<T>, options?: SchedulerPostTaskOptions): Promise<T>;
|
|
8565
8667
|
/**
|
|
8566
8668
|
* The **`yield()`** method of the Scheduler interface is used for yielding to the main thread during a task and continuing execution later, with the continuation scheduled as a prioritized task (see the Prioritized Task Scheduling API for more information). This allows long-running work to be broken up so the browser stays responsive.
|
|
8567
8669
|
*
|
|
@@ -13352,8 +13454,8 @@ interface ReportingObserverCallback {
|
|
|
13352
13454
|
(reports: Report[], observer: ReportingObserver): void;
|
|
13353
13455
|
}
|
|
13354
13456
|
|
|
13355
|
-
interface SchedulerPostTaskCallback {
|
|
13356
|
-
():
|
|
13457
|
+
interface SchedulerPostTaskCallback<T = any> {
|
|
13458
|
+
(): T | PromiseLike<T>;
|
|
13357
13459
|
}
|
|
13358
13460
|
|
|
13359
13461
|
interface TransformerFlushCallback<O> {
|
|
@@ -13552,7 +13654,7 @@ type AllowSharedBufferSource = ArrayBufferLike | ArrayBufferView<ArrayBufferLike
|
|
|
13552
13654
|
type BigInteger = Uint8Array<ArrayBuffer>;
|
|
13553
13655
|
type BlobPart = BufferSource | Blob | string;
|
|
13554
13656
|
type BodyInit = ReadableStream | XMLHttpRequestBodyInit;
|
|
13555
|
-
type BufferSource =
|
|
13657
|
+
type BufferSource = ArrayBuffer | ArrayBufferView<ArrayBuffer>;
|
|
13556
13658
|
type CSSKeywordish = string | CSSKeywordValue;
|
|
13557
13659
|
type CSSNumberish = number | CSSNumericValue;
|
|
13558
13660
|
type CSSPerspectiveValue = CSSNumericValue | CSSKeywordish;
|
|
@@ -13619,9 +13721,11 @@ type ReadableStreamReadResult<T> = ReadableStreamReadValueResult<T> | ReadableSt
|
|
|
13619
13721
|
type ReadableStreamReader<T> = ReadableStreamDefaultReader<T> | ReadableStreamBYOBReader;
|
|
13620
13722
|
type ReportList = Report[];
|
|
13621
13723
|
type RequestInfo = Request | string;
|
|
13724
|
+
type RouterSource = RouterSourceDict | RouterSourceEnum;
|
|
13622
13725
|
type TexImageSource = ImageBitmap | ImageData | OffscreenCanvas;
|
|
13623
13726
|
type TimerHandler = string | Function;
|
|
13624
13727
|
type Transferable = OffscreenCanvas | ImageBitmap | MessagePort | ReadableStream | WritableStream | TransformStream | ArrayBuffer;
|
|
13728
|
+
type URLPatternCompatible = string | URLPatternInit | URLPattern;
|
|
13625
13729
|
type URLPatternInput = string | URLPatternInit;
|
|
13626
13730
|
type Uint32List = Uint32Array<ArrayBufferLike> | GLuint[];
|
|
13627
13731
|
type XMLHttpRequestBodyInit = Blob | BufferSource | FormData | URLSearchParams | string;
|
|
@@ -13652,7 +13756,7 @@ type FontFaceSetLoadStatus = "loaded" | "loading";
|
|
|
13652
13756
|
type FrameType = "auxiliary" | "nested" | "none" | "top-level";
|
|
13653
13757
|
type GPUAddressMode = "clamp-to-edge" | "mirror-repeat" | "repeat";
|
|
13654
13758
|
type GPUAutoLayoutMode = "auto";
|
|
13655
|
-
type GPUBlendFactor = "constant" | "dst" | "dst-alpha" | "one" | "one-minus-constant" | "one-minus-dst" | "one-minus-dst-alpha" | "one-minus-src" | "one-minus-src-alpha" | "src" | "src-alpha" | "src-alpha-saturated" | "zero";
|
|
13759
|
+
type GPUBlendFactor = "constant" | "dst" | "dst-alpha" | "one" | "one-minus-constant" | "one-minus-dst" | "one-minus-dst-alpha" | "one-minus-src" | "one-minus-src-alpha" | "one-minus-src1" | "one-minus-src1-alpha" | "src" | "src-alpha" | "src-alpha-saturated" | "src1" | "src1-alpha" | "zero";
|
|
13656
13760
|
type GPUBlendOperation = "add" | "max" | "min" | "reverse-subtract" | "subtract";
|
|
13657
13761
|
type GPUBufferBindingType = "read-only-storage" | "storage" | "uniform";
|
|
13658
13762
|
type GPUBufferMapState = "mapped" | "pending" | "unmapped";
|
|
@@ -13663,7 +13767,7 @@ type GPUCompilationMessageType = "error" | "info" | "warning";
|
|
|
13663
13767
|
type GPUCullMode = "back" | "front" | "none";
|
|
13664
13768
|
type GPUDeviceLostReason = "destroyed" | "unknown";
|
|
13665
13769
|
type GPUErrorFilter = "internal" | "out-of-memory" | "validation";
|
|
13666
|
-
type GPUFeatureName = "bgra8unorm-storage" | "clip-distances" | "core-features-and-limits" | "depth-clip-control" | "depth32float-stencil8" | "dual-source-blending" | "float32-blendable" | "float32-filterable" | "indirect-first-instance" | "primitive-index" | "rg11b10ufloat-renderable" | "shader-f16" | "subgroups" | "texture-compression-astc" | "texture-compression-astc-sliced-3d" | "texture-compression-bc" | "texture-compression-bc-sliced-3d" | "texture-compression-etc2" | "texture-formats-tier1" | "timestamp-query";
|
|
13770
|
+
type GPUFeatureName = "bgra8unorm-storage" | "clip-distances" | "core-features-and-limits" | "depth-clip-control" | "depth32float-stencil8" | "dual-source-blending" | "float32-blendable" | "float32-filterable" | "indirect-first-instance" | "primitive-index" | "rg11b10ufloat-renderable" | "shader-f16" | "subgroups" | "texture-component-swizzle" | "texture-compression-astc" | "texture-compression-astc-sliced-3d" | "texture-compression-bc" | "texture-compression-bc-sliced-3d" | "texture-compression-etc2" | "texture-formats-tier1" | "texture-formats-tier2" | "timestamp-query";
|
|
13667
13771
|
type GPUFilterMode = "linear" | "nearest";
|
|
13668
13772
|
type GPUFrontFace = "ccw" | "cw";
|
|
13669
13773
|
type GPUIndexFormat = "uint16" | "uint32";
|
|
@@ -13719,6 +13823,8 @@ type RequestPriority = "auto" | "high" | "low";
|
|
|
13719
13823
|
type RequestRedirect = "error" | "follow" | "manual";
|
|
13720
13824
|
type ResizeQuality = "high" | "low" | "medium" | "pixelated";
|
|
13721
13825
|
type ResponseType = "basic" | "cors" | "default" | "error" | "opaque" | "opaqueredirect";
|
|
13826
|
+
type RouterSourceEnum = "cache" | "fetch-event" | "network" | "race-network-and-fetch-handler";
|
|
13827
|
+
type RunningStatus = "not-running" | "running";
|
|
13722
13828
|
type SecurityPolicyViolationEventDisposition = "enforce" | "report";
|
|
13723
13829
|
type ServiceWorkerState = "activated" | "activating" | "installed" | "installing" | "parsed" | "redundant";
|
|
13724
13830
|
type ServiceWorkerUpdateViaCache = "all" | "imports" | "none";
|
|
@@ -13913,6 +14019,15 @@ interface IDBObjectStore {
|
|
|
13913
14019
|
createIndex(name: string, keyPath: string | Iterable<string>, options?: IDBIndexParameters): IDBIndex;
|
|
13914
14020
|
}
|
|
13915
14021
|
|
|
14022
|
+
interface InstallEvent {
|
|
14023
|
+
/**
|
|
14024
|
+
* The **`addRoutes()`** method of the InstallEvent interface specifies one or more static routes, which define rules for fetching specified resources that will be used even before service worker startup. This allows you to, for example, bypass a service worker in cases where you always want to fetch a resource from the network or a browser Cache, and avoids the performance overhead of unnecessary service worker cycles.
|
|
14025
|
+
*
|
|
14026
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/InstallEvent/addRoutes)
|
|
14027
|
+
*/
|
|
14028
|
+
addRoutes(rules: RouterRule | Iterable<RouterRule>): Promise<void>;
|
|
14029
|
+
}
|
|
14030
|
+
|
|
13916
14031
|
interface MessageEvent<T = any> {
|
|
13917
14032
|
/** @deprecated */
|
|
13918
14033
|
initMessageEvent(type: string, bubbles?: boolean, cancelable?: boolean, data?: any, origin?: string, lastEventId?: string, source?: MessageEventSource | null, ports?: Iterable<MessagePort>): void;
|
package/package.json
CHANGED
package/ts5.5/index.d.ts
CHANGED
|
@@ -533,8 +533,10 @@ interface GPURenderPipelineDescriptor extends GPUPipelineDescriptorBase {
|
|
|
533
533
|
}
|
|
534
534
|
|
|
535
535
|
interface GPURequestAdapterOptions {
|
|
536
|
+
featureLevel?: string;
|
|
536
537
|
forceFallbackAdapter?: boolean;
|
|
537
538
|
powerPreference?: GPUPowerPreference;
|
|
539
|
+
xrCompatible?: boolean;
|
|
538
540
|
}
|
|
539
541
|
|
|
540
542
|
interface GPUSamplerBindingLayout {
|
|
@@ -554,8 +556,14 @@ interface GPUSamplerDescriptor extends GPUObjectDescriptorBase {
|
|
|
554
556
|
mipmapFilter?: GPUMipmapFilterMode;
|
|
555
557
|
}
|
|
556
558
|
|
|
559
|
+
interface GPUShaderModuleCompilationHint {
|
|
560
|
+
entryPoint: string;
|
|
561
|
+
layout?: GPUPipelineLayout | GPUAutoLayoutMode;
|
|
562
|
+
}
|
|
563
|
+
|
|
557
564
|
interface GPUShaderModuleDescriptor extends GPUObjectDescriptorBase {
|
|
558
565
|
code: string;
|
|
566
|
+
compilationHints?: GPUShaderModuleCompilationHint[];
|
|
559
567
|
}
|
|
560
568
|
|
|
561
569
|
interface GPUStencilFaceState {
|
|
@@ -612,6 +620,7 @@ interface GPUTextureViewDescriptor extends GPUObjectDescriptorBase {
|
|
|
612
620
|
dimension?: GPUTextureViewDimension;
|
|
613
621
|
format?: GPUTextureFormat;
|
|
614
622
|
mipLevelCount?: GPUIntegerCoordinate;
|
|
623
|
+
swizzle?: string;
|
|
615
624
|
usage?: GPUTextureUsageFlags;
|
|
616
625
|
}
|
|
617
626
|
|
|
@@ -660,6 +669,12 @@ interface IDBDatabaseInfo {
|
|
|
660
669
|
version?: number;
|
|
661
670
|
}
|
|
662
671
|
|
|
672
|
+
interface IDBGetAllOptions {
|
|
673
|
+
count?: number;
|
|
674
|
+
direction?: IDBCursorDirection;
|
|
675
|
+
query?: any;
|
|
676
|
+
}
|
|
677
|
+
|
|
663
678
|
interface IDBIndexParameters {
|
|
664
679
|
multiEntry?: boolean;
|
|
665
680
|
unique?: boolean;
|
|
@@ -875,7 +890,12 @@ interface PushSubscriptionChangeEventInit extends ExtendableEventInit {
|
|
|
875
890
|
interface PushSubscriptionJSON {
|
|
876
891
|
endpoint?: string;
|
|
877
892
|
expirationTime?: EpochTimeStamp | null;
|
|
878
|
-
keys?:
|
|
893
|
+
keys?: PushSubscriptionKeys;
|
|
894
|
+
}
|
|
895
|
+
|
|
896
|
+
interface PushSubscriptionKeys {
|
|
897
|
+
auth?: string;
|
|
898
|
+
p256dh?: string;
|
|
879
899
|
}
|
|
880
900
|
|
|
881
901
|
interface PushSubscriptionOptionsInit {
|
|
@@ -997,6 +1017,25 @@ interface ResponseInit {
|
|
|
997
1017
|
statusText?: string;
|
|
998
1018
|
}
|
|
999
1019
|
|
|
1020
|
+
interface RouterCondition {
|
|
1021
|
+
not?: RouterCondition;
|
|
1022
|
+
or?: RouterCondition[];
|
|
1023
|
+
requestDestination?: RequestDestination;
|
|
1024
|
+
requestMethod?: string;
|
|
1025
|
+
requestMode?: RequestMode;
|
|
1026
|
+
runningStatus?: RunningStatus;
|
|
1027
|
+
urlPattern?: URLPatternCompatible;
|
|
1028
|
+
}
|
|
1029
|
+
|
|
1030
|
+
interface RouterRule {
|
|
1031
|
+
condition: RouterCondition;
|
|
1032
|
+
source: RouterSource;
|
|
1033
|
+
}
|
|
1034
|
+
|
|
1035
|
+
interface RouterSourceDict {
|
|
1036
|
+
cacheName?: string;
|
|
1037
|
+
}
|
|
1038
|
+
|
|
1000
1039
|
interface RsaHashedImportParams extends Algorithm {
|
|
1001
1040
|
hash: HashAlgorithmIdentifier;
|
|
1002
1041
|
}
|
|
@@ -6165,6 +6204,12 @@ interface IDBIndex {
|
|
|
6165
6204
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/IDBIndex/getAllKeys)
|
|
6166
6205
|
*/
|
|
6167
6206
|
getAllKeys(queryOrOptions?: IDBValidKey | IDBKeyRange | null, count?: number): IDBRequest<IDBValidKey[]>;
|
|
6207
|
+
/**
|
|
6208
|
+
* The **`getAllRecords()`** method of the IDBIndex interface retrieves all records (including index keys, primary keys, and values) from the index.
|
|
6209
|
+
*
|
|
6210
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/IDBIndex/getAllRecords)
|
|
6211
|
+
*/
|
|
6212
|
+
getAllRecords(options?: IDBGetAllOptions): IDBRequest;
|
|
6168
6213
|
/**
|
|
6169
6214
|
* The **`getKey()`** method of the IDBIndex interface returns an IDBRequest object, and, in a separate thread, finds either the primary key that corresponds to the given key in this index or the first corresponding primary key, if key is set to an IDBKeyRange.
|
|
6170
6215
|
*
|
|
@@ -6347,6 +6392,12 @@ interface IDBObjectStore {
|
|
|
6347
6392
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/IDBObjectStore/getAllKeys)
|
|
6348
6393
|
*/
|
|
6349
6394
|
getAllKeys(queryOrOptions?: IDBValidKey | IDBKeyRange | null, count?: number): IDBRequest<IDBValidKey[]>;
|
|
6395
|
+
/**
|
|
6396
|
+
* The **`getAllRecords()`** method of the IDBObjectStore interface retrieves all records (including primary keys and values) from the object store.
|
|
6397
|
+
*
|
|
6398
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/IDBObjectStore/getAllRecords)
|
|
6399
|
+
*/
|
|
6400
|
+
getAllRecords(options?: IDBGetAllOptions): IDBRequest;
|
|
6350
6401
|
/**
|
|
6351
6402
|
* The **`getKey()`** method of the IDBObjectStore interface returns an IDBRequest object, and, in a separate thread, returns the key selected by the specified query. This is for retrieving specific records from an object store.
|
|
6352
6403
|
*
|
|
@@ -6410,6 +6461,18 @@ declare var IDBOpenDBRequest: {
|
|
|
6410
6461
|
new(): IDBOpenDBRequest;
|
|
6411
6462
|
};
|
|
6412
6463
|
|
|
6464
|
+
/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/IDBRecord) */
|
|
6465
|
+
interface IDBRecord {
|
|
6466
|
+
readonly key: any;
|
|
6467
|
+
readonly primaryKey: any;
|
|
6468
|
+
readonly value: any;
|
|
6469
|
+
}
|
|
6470
|
+
|
|
6471
|
+
declare var IDBRecord: {
|
|
6472
|
+
prototype: IDBRecord;
|
|
6473
|
+
new(): IDBRecord;
|
|
6474
|
+
};
|
|
6475
|
+
|
|
6413
6476
|
interface IDBRequestEventMap {
|
|
6414
6477
|
"error": Event;
|
|
6415
6478
|
"success": Event;
|
|
@@ -6661,6 +6724,25 @@ interface ImportMeta {
|
|
|
6661
6724
|
resolve(specifier: string): string;
|
|
6662
6725
|
}
|
|
6663
6726
|
|
|
6727
|
+
/**
|
|
6728
|
+
* The parameter passed into an install event handler function, the **`InstallEvent`** interface represents an install action that is dispatched on the ServiceWorkerGlobalScope of a ServiceWorker. As a child of ExtendableEvent, it ensures that functional events such as FetchEvent are not dispatched during installation.
|
|
6729
|
+
*
|
|
6730
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/InstallEvent)
|
|
6731
|
+
*/
|
|
6732
|
+
interface InstallEvent extends ExtendableEvent {
|
|
6733
|
+
/**
|
|
6734
|
+
* The **`addRoutes()`** method of the InstallEvent interface specifies one or more static routes, which define rules for fetching specified resources that will be used even before service worker startup. This allows you to, for example, bypass a service worker in cases where you always want to fetch a resource from the network or a browser Cache, and avoids the performance overhead of unnecessary service worker cycles.
|
|
6735
|
+
*
|
|
6736
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/InstallEvent/addRoutes)
|
|
6737
|
+
*/
|
|
6738
|
+
addRoutes(rules: RouterRule | RouterRule[]): Promise<void>;
|
|
6739
|
+
}
|
|
6740
|
+
|
|
6741
|
+
declare var InstallEvent: {
|
|
6742
|
+
prototype: InstallEvent;
|
|
6743
|
+
new(type: string, eventInitDict?: ExtendableEventInit): InstallEvent;
|
|
6744
|
+
};
|
|
6745
|
+
|
|
6664
6746
|
/**
|
|
6665
6747
|
* The **`KHR_parallel_shader_compile`** extension is part of the WebGL API and enables a non-blocking poll operation, so that compile/link status availability (COMPLETION_STATUS_KHR) can be queried without potentially incurring stalls. In other words you can check the status of your shaders compiling without blocking the runtime.
|
|
6666
6748
|
*
|
|
@@ -7422,12 +7504,18 @@ interface Performance extends EventTarget {
|
|
|
7422
7504
|
*
|
|
7423
7505
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/Performance/getEntriesByName)
|
|
7424
7506
|
*/
|
|
7507
|
+
getEntriesByName(name: string, type: "mark"): PerformanceMark[];
|
|
7508
|
+
getEntriesByName(name: string, type: "measure"): PerformanceMeasure[];
|
|
7509
|
+
getEntriesByName(name: string, type: "resource"): PerformanceResourceTiming[];
|
|
7425
7510
|
getEntriesByName(name: string, type?: string): PerformanceEntryList;
|
|
7426
7511
|
/**
|
|
7427
7512
|
* The **`getEntriesByType()`** method returns an array of PerformanceEntry objects currently present in the performance timeline for a given type.
|
|
7428
7513
|
*
|
|
7429
7514
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/Performance/getEntriesByType)
|
|
7430
7515
|
*/
|
|
7516
|
+
getEntriesByType(type: "mark"): PerformanceMark[];
|
|
7517
|
+
getEntriesByType(type: "measure"): PerformanceMeasure[];
|
|
7518
|
+
getEntriesByType(type: "resource"): PerformanceResourceTiming[];
|
|
7431
7519
|
getEntriesByType(type: string): PerformanceEntryList;
|
|
7432
7520
|
/**
|
|
7433
7521
|
* The **`mark()`** method creates a named PerformanceMark object representing a high resolution timestamp marker in the browser's performance timeline.
|
|
@@ -7605,12 +7693,18 @@ interface PerformanceObserverEntryList {
|
|
|
7605
7693
|
*
|
|
7606
7694
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/PerformanceObserverEntryList/getEntriesByName)
|
|
7607
7695
|
*/
|
|
7696
|
+
getEntriesByName(name: string, type: "mark"): PerformanceMark[];
|
|
7697
|
+
getEntriesByName(name: string, type: "measure"): PerformanceMeasure[];
|
|
7698
|
+
getEntriesByName(name: string, type: "resource"): PerformanceResourceTiming[];
|
|
7608
7699
|
getEntriesByName(name: string, type?: string): PerformanceEntryList;
|
|
7609
7700
|
/**
|
|
7610
7701
|
* The **`getEntriesByType()`** method of the PerformanceObserverEntryList returns a list of explicitly observed performance entry objects for a given performance entry type. The list's members are determined by the set of entry types specified in the call to the observe() method. The list is available in the observer's callback function (as the first parameter in the callback).
|
|
7611
7702
|
*
|
|
7612
7703
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/PerformanceObserverEntryList/getEntriesByType)
|
|
7613
7704
|
*/
|
|
7705
|
+
getEntriesByType(type: "mark"): PerformanceMark[];
|
|
7706
|
+
getEntriesByType(type: "measure"): PerformanceMeasure[];
|
|
7707
|
+
getEntriesByType(type: "resource"): PerformanceResourceTiming[];
|
|
7614
7708
|
getEntriesByType(type: string): PerformanceEntryList;
|
|
7615
7709
|
}
|
|
7616
7710
|
|
|
@@ -7757,6 +7851,8 @@ interface PerformanceResourceTiming extends PerformanceEntry {
|
|
|
7757
7851
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/PerformanceResourceTiming/transferSize)
|
|
7758
7852
|
*/
|
|
7759
7853
|
readonly transferSize: number;
|
|
7854
|
+
readonly workerCacheLookupStart: DOMHighResTimeStamp;
|
|
7855
|
+
readonly workerRouterEvaluationStart: DOMHighResTimeStamp;
|
|
7760
7856
|
/**
|
|
7761
7857
|
* The **`workerStart`** read-only property of the PerformanceResourceTiming interface returns a DOMHighResTimeStamp immediately before dispatching the FetchEvent if a Service Worker thread is already running, or immediately before starting the Service Worker thread if it is not already running. If the resource is not intercepted by a Service Worker the property will always return 0.
|
|
7762
7858
|
*
|
|
@@ -8213,6 +8309,12 @@ declare var ReadableStream: {
|
|
|
8213
8309
|
new(underlyingSource: UnderlyingByteSource, strategy?: { highWaterMark?: number }): ReadableStream<Uint8Array>;
|
|
8214
8310
|
new<R = any>(underlyingSource: UnderlyingDefaultSource<R>, strategy?: QueuingStrategy<R>): ReadableStream<R>;
|
|
8215
8311
|
new<R = any>(underlyingSource?: UnderlyingSource<R>, strategy?: QueuingStrategy<R>): ReadableStream<R>;
|
|
8312
|
+
/**
|
|
8313
|
+
* The **`ReadableStream.from()`** static method returns a ReadableStream from a provided iterable or async iterable object.
|
|
8314
|
+
*
|
|
8315
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableStream/from_static)
|
|
8316
|
+
*/
|
|
8317
|
+
from(asyncIterable: Iterable<any>): ReadableStream;
|
|
8216
8318
|
};
|
|
8217
8319
|
|
|
8218
8320
|
/**
|
|
@@ -8558,7 +8660,7 @@ interface Scheduler {
|
|
|
8558
8660
|
*
|
|
8559
8661
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/Scheduler/postTask)
|
|
8560
8662
|
*/
|
|
8561
|
-
postTask(callback: SchedulerPostTaskCallback
|
|
8663
|
+
postTask<T = any>(callback: SchedulerPostTaskCallback<T>, options?: SchedulerPostTaskOptions): Promise<T>;
|
|
8562
8664
|
/**
|
|
8563
8665
|
* The **`yield()`** method of the Scheduler interface is used for yielding to the main thread during a task and continuing execution later, with the continuation scheduled as a prioritized task (see the Prioritized Task Scheduling API for more information). This allows long-running work to be broken up so the browser stays responsive.
|
|
8564
8666
|
*
|
|
@@ -13349,8 +13451,8 @@ interface ReportingObserverCallback {
|
|
|
13349
13451
|
(reports: Report[], observer: ReportingObserver): void;
|
|
13350
13452
|
}
|
|
13351
13453
|
|
|
13352
|
-
interface SchedulerPostTaskCallback {
|
|
13353
|
-
():
|
|
13454
|
+
interface SchedulerPostTaskCallback<T = any> {
|
|
13455
|
+
(): T | PromiseLike<T>;
|
|
13354
13456
|
}
|
|
13355
13457
|
|
|
13356
13458
|
interface TransformerFlushCallback<O> {
|
|
@@ -13549,7 +13651,7 @@ type AllowSharedBufferSource = ArrayBufferLike | ArrayBufferView;
|
|
|
13549
13651
|
type BigInteger = Uint8Array;
|
|
13550
13652
|
type BlobPart = BufferSource | Blob | string;
|
|
13551
13653
|
type BodyInit = ReadableStream | XMLHttpRequestBodyInit;
|
|
13552
|
-
type BufferSource =
|
|
13654
|
+
type BufferSource = ArrayBuffer | ArrayBufferView;
|
|
13553
13655
|
type CSSKeywordish = string | CSSKeywordValue;
|
|
13554
13656
|
type CSSNumberish = number | CSSNumericValue;
|
|
13555
13657
|
type CSSPerspectiveValue = CSSNumericValue | CSSKeywordish;
|
|
@@ -13616,9 +13718,11 @@ type ReadableStreamReadResult<T> = ReadableStreamReadValueResult<T> | ReadableSt
|
|
|
13616
13718
|
type ReadableStreamReader<T> = ReadableStreamDefaultReader<T> | ReadableStreamBYOBReader;
|
|
13617
13719
|
type ReportList = Report[];
|
|
13618
13720
|
type RequestInfo = Request | string;
|
|
13721
|
+
type RouterSource = RouterSourceDict | RouterSourceEnum;
|
|
13619
13722
|
type TexImageSource = ImageBitmap | ImageData | OffscreenCanvas;
|
|
13620
13723
|
type TimerHandler = string | Function;
|
|
13621
13724
|
type Transferable = OffscreenCanvas | ImageBitmap | MessagePort | ReadableStream | WritableStream | TransformStream | ArrayBuffer;
|
|
13725
|
+
type URLPatternCompatible = string | URLPatternInit | URLPattern;
|
|
13622
13726
|
type URLPatternInput = string | URLPatternInit;
|
|
13623
13727
|
type Uint32List = Uint32Array | GLuint[];
|
|
13624
13728
|
type XMLHttpRequestBodyInit = Blob | BufferSource | FormData | URLSearchParams | string;
|
|
@@ -13649,7 +13753,7 @@ type FontFaceSetLoadStatus = "loaded" | "loading";
|
|
|
13649
13753
|
type FrameType = "auxiliary" | "nested" | "none" | "top-level";
|
|
13650
13754
|
type GPUAddressMode = "clamp-to-edge" | "mirror-repeat" | "repeat";
|
|
13651
13755
|
type GPUAutoLayoutMode = "auto";
|
|
13652
|
-
type GPUBlendFactor = "constant" | "dst" | "dst-alpha" | "one" | "one-minus-constant" | "one-minus-dst" | "one-minus-dst-alpha" | "one-minus-src" | "one-minus-src-alpha" | "src" | "src-alpha" | "src-alpha-saturated" | "zero";
|
|
13756
|
+
type GPUBlendFactor = "constant" | "dst" | "dst-alpha" | "one" | "one-minus-constant" | "one-minus-dst" | "one-minus-dst-alpha" | "one-minus-src" | "one-minus-src-alpha" | "one-minus-src1" | "one-minus-src1-alpha" | "src" | "src-alpha" | "src-alpha-saturated" | "src1" | "src1-alpha" | "zero";
|
|
13653
13757
|
type GPUBlendOperation = "add" | "max" | "min" | "reverse-subtract" | "subtract";
|
|
13654
13758
|
type GPUBufferBindingType = "read-only-storage" | "storage" | "uniform";
|
|
13655
13759
|
type GPUBufferMapState = "mapped" | "pending" | "unmapped";
|
|
@@ -13660,7 +13764,7 @@ type GPUCompilationMessageType = "error" | "info" | "warning";
|
|
|
13660
13764
|
type GPUCullMode = "back" | "front" | "none";
|
|
13661
13765
|
type GPUDeviceLostReason = "destroyed" | "unknown";
|
|
13662
13766
|
type GPUErrorFilter = "internal" | "out-of-memory" | "validation";
|
|
13663
|
-
type GPUFeatureName = "bgra8unorm-storage" | "clip-distances" | "core-features-and-limits" | "depth-clip-control" | "depth32float-stencil8" | "dual-source-blending" | "float32-blendable" | "float32-filterable" | "indirect-first-instance" | "primitive-index" | "rg11b10ufloat-renderable" | "shader-f16" | "subgroups" | "texture-compression-astc" | "texture-compression-astc-sliced-3d" | "texture-compression-bc" | "texture-compression-bc-sliced-3d" | "texture-compression-etc2" | "texture-formats-tier1" | "timestamp-query";
|
|
13767
|
+
type GPUFeatureName = "bgra8unorm-storage" | "clip-distances" | "core-features-and-limits" | "depth-clip-control" | "depth32float-stencil8" | "dual-source-blending" | "float32-blendable" | "float32-filterable" | "indirect-first-instance" | "primitive-index" | "rg11b10ufloat-renderable" | "shader-f16" | "subgroups" | "texture-component-swizzle" | "texture-compression-astc" | "texture-compression-astc-sliced-3d" | "texture-compression-bc" | "texture-compression-bc-sliced-3d" | "texture-compression-etc2" | "texture-formats-tier1" | "texture-formats-tier2" | "timestamp-query";
|
|
13664
13768
|
type GPUFilterMode = "linear" | "nearest";
|
|
13665
13769
|
type GPUFrontFace = "ccw" | "cw";
|
|
13666
13770
|
type GPUIndexFormat = "uint16" | "uint32";
|
|
@@ -13716,6 +13820,8 @@ type RequestPriority = "auto" | "high" | "low";
|
|
|
13716
13820
|
type RequestRedirect = "error" | "follow" | "manual";
|
|
13717
13821
|
type ResizeQuality = "high" | "low" | "medium" | "pixelated";
|
|
13718
13822
|
type ResponseType = "basic" | "cors" | "default" | "error" | "opaque" | "opaqueredirect";
|
|
13823
|
+
type RouterSourceEnum = "cache" | "fetch-event" | "network" | "race-network-and-fetch-handler";
|
|
13824
|
+
type RunningStatus = "not-running" | "running";
|
|
13719
13825
|
type SecurityPolicyViolationEventDisposition = "enforce" | "report";
|
|
13720
13826
|
type ServiceWorkerState = "activated" | "activating" | "installed" | "installing" | "parsed" | "redundant";
|
|
13721
13827
|
type ServiceWorkerUpdateViaCache = "all" | "imports" | "none";
|
package/ts5.5/iterable.d.ts
CHANGED
|
@@ -171,6 +171,15 @@ interface IDBObjectStore {
|
|
|
171
171
|
createIndex(name: string, keyPath: string | Iterable<string>, options?: IDBIndexParameters): IDBIndex;
|
|
172
172
|
}
|
|
173
173
|
|
|
174
|
+
interface InstallEvent {
|
|
175
|
+
/**
|
|
176
|
+
* The **`addRoutes()`** method of the InstallEvent interface specifies one or more static routes, which define rules for fetching specified resources that will be used even before service worker startup. This allows you to, for example, bypass a service worker in cases where you always want to fetch a resource from the network or a browser Cache, and avoids the performance overhead of unnecessary service worker cycles.
|
|
177
|
+
*
|
|
178
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/InstallEvent/addRoutes)
|
|
179
|
+
*/
|
|
180
|
+
addRoutes(rules: RouterRule | Iterable<RouterRule>): Promise<void>;
|
|
181
|
+
}
|
|
182
|
+
|
|
174
183
|
interface MessageEvent<T = any> {
|
|
175
184
|
/** @deprecated */
|
|
176
185
|
initMessageEvent(type: string, bubbles?: boolean, cancelable?: boolean, data?: any, origin?: string, lastEventId?: string, source?: MessageEventSource | null, ports?: Iterable<MessagePort>): void;
|
package/ts5.6/index.d.ts
CHANGED
|
@@ -533,8 +533,10 @@ interface GPURenderPipelineDescriptor extends GPUPipelineDescriptorBase {
|
|
|
533
533
|
}
|
|
534
534
|
|
|
535
535
|
interface GPURequestAdapterOptions {
|
|
536
|
+
featureLevel?: string;
|
|
536
537
|
forceFallbackAdapter?: boolean;
|
|
537
538
|
powerPreference?: GPUPowerPreference;
|
|
539
|
+
xrCompatible?: boolean;
|
|
538
540
|
}
|
|
539
541
|
|
|
540
542
|
interface GPUSamplerBindingLayout {
|
|
@@ -554,8 +556,14 @@ interface GPUSamplerDescriptor extends GPUObjectDescriptorBase {
|
|
|
554
556
|
mipmapFilter?: GPUMipmapFilterMode;
|
|
555
557
|
}
|
|
556
558
|
|
|
559
|
+
interface GPUShaderModuleCompilationHint {
|
|
560
|
+
entryPoint: string;
|
|
561
|
+
layout?: GPUPipelineLayout | GPUAutoLayoutMode;
|
|
562
|
+
}
|
|
563
|
+
|
|
557
564
|
interface GPUShaderModuleDescriptor extends GPUObjectDescriptorBase {
|
|
558
565
|
code: string;
|
|
566
|
+
compilationHints?: GPUShaderModuleCompilationHint[];
|
|
559
567
|
}
|
|
560
568
|
|
|
561
569
|
interface GPUStencilFaceState {
|
|
@@ -612,6 +620,7 @@ interface GPUTextureViewDescriptor extends GPUObjectDescriptorBase {
|
|
|
612
620
|
dimension?: GPUTextureViewDimension;
|
|
613
621
|
format?: GPUTextureFormat;
|
|
614
622
|
mipLevelCount?: GPUIntegerCoordinate;
|
|
623
|
+
swizzle?: string;
|
|
615
624
|
usage?: GPUTextureUsageFlags;
|
|
616
625
|
}
|
|
617
626
|
|
|
@@ -660,6 +669,12 @@ interface IDBDatabaseInfo {
|
|
|
660
669
|
version?: number;
|
|
661
670
|
}
|
|
662
671
|
|
|
672
|
+
interface IDBGetAllOptions {
|
|
673
|
+
count?: number;
|
|
674
|
+
direction?: IDBCursorDirection;
|
|
675
|
+
query?: any;
|
|
676
|
+
}
|
|
677
|
+
|
|
663
678
|
interface IDBIndexParameters {
|
|
664
679
|
multiEntry?: boolean;
|
|
665
680
|
unique?: boolean;
|
|
@@ -875,7 +890,12 @@ interface PushSubscriptionChangeEventInit extends ExtendableEventInit {
|
|
|
875
890
|
interface PushSubscriptionJSON {
|
|
876
891
|
endpoint?: string;
|
|
877
892
|
expirationTime?: EpochTimeStamp | null;
|
|
878
|
-
keys?:
|
|
893
|
+
keys?: PushSubscriptionKeys;
|
|
894
|
+
}
|
|
895
|
+
|
|
896
|
+
interface PushSubscriptionKeys {
|
|
897
|
+
auth?: string;
|
|
898
|
+
p256dh?: string;
|
|
879
899
|
}
|
|
880
900
|
|
|
881
901
|
interface PushSubscriptionOptionsInit {
|
|
@@ -997,6 +1017,25 @@ interface ResponseInit {
|
|
|
997
1017
|
statusText?: string;
|
|
998
1018
|
}
|
|
999
1019
|
|
|
1020
|
+
interface RouterCondition {
|
|
1021
|
+
not?: RouterCondition;
|
|
1022
|
+
or?: RouterCondition[];
|
|
1023
|
+
requestDestination?: RequestDestination;
|
|
1024
|
+
requestMethod?: string;
|
|
1025
|
+
requestMode?: RequestMode;
|
|
1026
|
+
runningStatus?: RunningStatus;
|
|
1027
|
+
urlPattern?: URLPatternCompatible;
|
|
1028
|
+
}
|
|
1029
|
+
|
|
1030
|
+
interface RouterRule {
|
|
1031
|
+
condition: RouterCondition;
|
|
1032
|
+
source: RouterSource;
|
|
1033
|
+
}
|
|
1034
|
+
|
|
1035
|
+
interface RouterSourceDict {
|
|
1036
|
+
cacheName?: string;
|
|
1037
|
+
}
|
|
1038
|
+
|
|
1000
1039
|
interface RsaHashedImportParams extends Algorithm {
|
|
1001
1040
|
hash: HashAlgorithmIdentifier;
|
|
1002
1041
|
}
|
|
@@ -6165,6 +6204,12 @@ interface IDBIndex {
|
|
|
6165
6204
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/IDBIndex/getAllKeys)
|
|
6166
6205
|
*/
|
|
6167
6206
|
getAllKeys(queryOrOptions?: IDBValidKey | IDBKeyRange | null, count?: number): IDBRequest<IDBValidKey[]>;
|
|
6207
|
+
/**
|
|
6208
|
+
* The **`getAllRecords()`** method of the IDBIndex interface retrieves all records (including index keys, primary keys, and values) from the index.
|
|
6209
|
+
*
|
|
6210
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/IDBIndex/getAllRecords)
|
|
6211
|
+
*/
|
|
6212
|
+
getAllRecords(options?: IDBGetAllOptions): IDBRequest;
|
|
6168
6213
|
/**
|
|
6169
6214
|
* The **`getKey()`** method of the IDBIndex interface returns an IDBRequest object, and, in a separate thread, finds either the primary key that corresponds to the given key in this index or the first corresponding primary key, if key is set to an IDBKeyRange.
|
|
6170
6215
|
*
|
|
@@ -6347,6 +6392,12 @@ interface IDBObjectStore {
|
|
|
6347
6392
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/IDBObjectStore/getAllKeys)
|
|
6348
6393
|
*/
|
|
6349
6394
|
getAllKeys(queryOrOptions?: IDBValidKey | IDBKeyRange | null, count?: number): IDBRequest<IDBValidKey[]>;
|
|
6395
|
+
/**
|
|
6396
|
+
* The **`getAllRecords()`** method of the IDBObjectStore interface retrieves all records (including primary keys and values) from the object store.
|
|
6397
|
+
*
|
|
6398
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/IDBObjectStore/getAllRecords)
|
|
6399
|
+
*/
|
|
6400
|
+
getAllRecords(options?: IDBGetAllOptions): IDBRequest;
|
|
6350
6401
|
/**
|
|
6351
6402
|
* The **`getKey()`** method of the IDBObjectStore interface returns an IDBRequest object, and, in a separate thread, returns the key selected by the specified query. This is for retrieving specific records from an object store.
|
|
6352
6403
|
*
|
|
@@ -6410,6 +6461,18 @@ declare var IDBOpenDBRequest: {
|
|
|
6410
6461
|
new(): IDBOpenDBRequest;
|
|
6411
6462
|
};
|
|
6412
6463
|
|
|
6464
|
+
/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/IDBRecord) */
|
|
6465
|
+
interface IDBRecord {
|
|
6466
|
+
readonly key: any;
|
|
6467
|
+
readonly primaryKey: any;
|
|
6468
|
+
readonly value: any;
|
|
6469
|
+
}
|
|
6470
|
+
|
|
6471
|
+
declare var IDBRecord: {
|
|
6472
|
+
prototype: IDBRecord;
|
|
6473
|
+
new(): IDBRecord;
|
|
6474
|
+
};
|
|
6475
|
+
|
|
6413
6476
|
interface IDBRequestEventMap {
|
|
6414
6477
|
"error": Event;
|
|
6415
6478
|
"success": Event;
|
|
@@ -6661,6 +6724,25 @@ interface ImportMeta {
|
|
|
6661
6724
|
resolve(specifier: string): string;
|
|
6662
6725
|
}
|
|
6663
6726
|
|
|
6727
|
+
/**
|
|
6728
|
+
* The parameter passed into an install event handler function, the **`InstallEvent`** interface represents an install action that is dispatched on the ServiceWorkerGlobalScope of a ServiceWorker. As a child of ExtendableEvent, it ensures that functional events such as FetchEvent are not dispatched during installation.
|
|
6729
|
+
*
|
|
6730
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/InstallEvent)
|
|
6731
|
+
*/
|
|
6732
|
+
interface InstallEvent extends ExtendableEvent {
|
|
6733
|
+
/**
|
|
6734
|
+
* The **`addRoutes()`** method of the InstallEvent interface specifies one or more static routes, which define rules for fetching specified resources that will be used even before service worker startup. This allows you to, for example, bypass a service worker in cases where you always want to fetch a resource from the network or a browser Cache, and avoids the performance overhead of unnecessary service worker cycles.
|
|
6735
|
+
*
|
|
6736
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/InstallEvent/addRoutes)
|
|
6737
|
+
*/
|
|
6738
|
+
addRoutes(rules: RouterRule | RouterRule[]): Promise<void>;
|
|
6739
|
+
}
|
|
6740
|
+
|
|
6741
|
+
declare var InstallEvent: {
|
|
6742
|
+
prototype: InstallEvent;
|
|
6743
|
+
new(type: string, eventInitDict?: ExtendableEventInit): InstallEvent;
|
|
6744
|
+
};
|
|
6745
|
+
|
|
6664
6746
|
/**
|
|
6665
6747
|
* The **`KHR_parallel_shader_compile`** extension is part of the WebGL API and enables a non-blocking poll operation, so that compile/link status availability (COMPLETION_STATUS_KHR) can be queried without potentially incurring stalls. In other words you can check the status of your shaders compiling without blocking the runtime.
|
|
6666
6748
|
*
|
|
@@ -7422,12 +7504,18 @@ interface Performance extends EventTarget {
|
|
|
7422
7504
|
*
|
|
7423
7505
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/Performance/getEntriesByName)
|
|
7424
7506
|
*/
|
|
7507
|
+
getEntriesByName(name: string, type: "mark"): PerformanceMark[];
|
|
7508
|
+
getEntriesByName(name: string, type: "measure"): PerformanceMeasure[];
|
|
7509
|
+
getEntriesByName(name: string, type: "resource"): PerformanceResourceTiming[];
|
|
7425
7510
|
getEntriesByName(name: string, type?: string): PerformanceEntryList;
|
|
7426
7511
|
/**
|
|
7427
7512
|
* The **`getEntriesByType()`** method returns an array of PerformanceEntry objects currently present in the performance timeline for a given type.
|
|
7428
7513
|
*
|
|
7429
7514
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/Performance/getEntriesByType)
|
|
7430
7515
|
*/
|
|
7516
|
+
getEntriesByType(type: "mark"): PerformanceMark[];
|
|
7517
|
+
getEntriesByType(type: "measure"): PerformanceMeasure[];
|
|
7518
|
+
getEntriesByType(type: "resource"): PerformanceResourceTiming[];
|
|
7431
7519
|
getEntriesByType(type: string): PerformanceEntryList;
|
|
7432
7520
|
/**
|
|
7433
7521
|
* The **`mark()`** method creates a named PerformanceMark object representing a high resolution timestamp marker in the browser's performance timeline.
|
|
@@ -7605,12 +7693,18 @@ interface PerformanceObserverEntryList {
|
|
|
7605
7693
|
*
|
|
7606
7694
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/PerformanceObserverEntryList/getEntriesByName)
|
|
7607
7695
|
*/
|
|
7696
|
+
getEntriesByName(name: string, type: "mark"): PerformanceMark[];
|
|
7697
|
+
getEntriesByName(name: string, type: "measure"): PerformanceMeasure[];
|
|
7698
|
+
getEntriesByName(name: string, type: "resource"): PerformanceResourceTiming[];
|
|
7608
7699
|
getEntriesByName(name: string, type?: string): PerformanceEntryList;
|
|
7609
7700
|
/**
|
|
7610
7701
|
* The **`getEntriesByType()`** method of the PerformanceObserverEntryList returns a list of explicitly observed performance entry objects for a given performance entry type. The list's members are determined by the set of entry types specified in the call to the observe() method. The list is available in the observer's callback function (as the first parameter in the callback).
|
|
7611
7702
|
*
|
|
7612
7703
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/PerformanceObserverEntryList/getEntriesByType)
|
|
7613
7704
|
*/
|
|
7705
|
+
getEntriesByType(type: "mark"): PerformanceMark[];
|
|
7706
|
+
getEntriesByType(type: "measure"): PerformanceMeasure[];
|
|
7707
|
+
getEntriesByType(type: "resource"): PerformanceResourceTiming[];
|
|
7614
7708
|
getEntriesByType(type: string): PerformanceEntryList;
|
|
7615
7709
|
}
|
|
7616
7710
|
|
|
@@ -7757,6 +7851,8 @@ interface PerformanceResourceTiming extends PerformanceEntry {
|
|
|
7757
7851
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/PerformanceResourceTiming/transferSize)
|
|
7758
7852
|
*/
|
|
7759
7853
|
readonly transferSize: number;
|
|
7854
|
+
readonly workerCacheLookupStart: DOMHighResTimeStamp;
|
|
7855
|
+
readonly workerRouterEvaluationStart: DOMHighResTimeStamp;
|
|
7760
7856
|
/**
|
|
7761
7857
|
* The **`workerStart`** read-only property of the PerformanceResourceTiming interface returns a DOMHighResTimeStamp immediately before dispatching the FetchEvent if a Service Worker thread is already running, or immediately before starting the Service Worker thread if it is not already running. If the resource is not intercepted by a Service Worker the property will always return 0.
|
|
7762
7858
|
*
|
|
@@ -8213,6 +8309,12 @@ declare var ReadableStream: {
|
|
|
8213
8309
|
new(underlyingSource: UnderlyingByteSource, strategy?: { highWaterMark?: number }): ReadableStream<Uint8Array>;
|
|
8214
8310
|
new<R = any>(underlyingSource: UnderlyingDefaultSource<R>, strategy?: QueuingStrategy<R>): ReadableStream<R>;
|
|
8215
8311
|
new<R = any>(underlyingSource?: UnderlyingSource<R>, strategy?: QueuingStrategy<R>): ReadableStream<R>;
|
|
8312
|
+
/**
|
|
8313
|
+
* The **`ReadableStream.from()`** static method returns a ReadableStream from a provided iterable or async iterable object.
|
|
8314
|
+
*
|
|
8315
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableStream/from_static)
|
|
8316
|
+
*/
|
|
8317
|
+
from(asyncIterable: Iterable<any>): ReadableStream;
|
|
8216
8318
|
};
|
|
8217
8319
|
|
|
8218
8320
|
/**
|
|
@@ -8558,7 +8660,7 @@ interface Scheduler {
|
|
|
8558
8660
|
*
|
|
8559
8661
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/Scheduler/postTask)
|
|
8560
8662
|
*/
|
|
8561
|
-
postTask(callback: SchedulerPostTaskCallback
|
|
8663
|
+
postTask<T = any>(callback: SchedulerPostTaskCallback<T>, options?: SchedulerPostTaskOptions): Promise<T>;
|
|
8562
8664
|
/**
|
|
8563
8665
|
* The **`yield()`** method of the Scheduler interface is used for yielding to the main thread during a task and continuing execution later, with the continuation scheduled as a prioritized task (see the Prioritized Task Scheduling API for more information). This allows long-running work to be broken up so the browser stays responsive.
|
|
8564
8666
|
*
|
|
@@ -13349,8 +13451,8 @@ interface ReportingObserverCallback {
|
|
|
13349
13451
|
(reports: Report[], observer: ReportingObserver): void;
|
|
13350
13452
|
}
|
|
13351
13453
|
|
|
13352
|
-
interface SchedulerPostTaskCallback {
|
|
13353
|
-
():
|
|
13454
|
+
interface SchedulerPostTaskCallback<T = any> {
|
|
13455
|
+
(): T | PromiseLike<T>;
|
|
13354
13456
|
}
|
|
13355
13457
|
|
|
13356
13458
|
interface TransformerFlushCallback<O> {
|
|
@@ -13549,7 +13651,7 @@ type AllowSharedBufferSource = ArrayBufferLike | ArrayBufferView;
|
|
|
13549
13651
|
type BigInteger = Uint8Array;
|
|
13550
13652
|
type BlobPart = BufferSource | Blob | string;
|
|
13551
13653
|
type BodyInit = ReadableStream | XMLHttpRequestBodyInit;
|
|
13552
|
-
type BufferSource =
|
|
13654
|
+
type BufferSource = ArrayBuffer | ArrayBufferView;
|
|
13553
13655
|
type CSSKeywordish = string | CSSKeywordValue;
|
|
13554
13656
|
type CSSNumberish = number | CSSNumericValue;
|
|
13555
13657
|
type CSSPerspectiveValue = CSSNumericValue | CSSKeywordish;
|
|
@@ -13616,9 +13718,11 @@ type ReadableStreamReadResult<T> = ReadableStreamReadValueResult<T> | ReadableSt
|
|
|
13616
13718
|
type ReadableStreamReader<T> = ReadableStreamDefaultReader<T> | ReadableStreamBYOBReader;
|
|
13617
13719
|
type ReportList = Report[];
|
|
13618
13720
|
type RequestInfo = Request | string;
|
|
13721
|
+
type RouterSource = RouterSourceDict | RouterSourceEnum;
|
|
13619
13722
|
type TexImageSource = ImageBitmap | ImageData | OffscreenCanvas;
|
|
13620
13723
|
type TimerHandler = string | Function;
|
|
13621
13724
|
type Transferable = OffscreenCanvas | ImageBitmap | MessagePort | ReadableStream | WritableStream | TransformStream | ArrayBuffer;
|
|
13725
|
+
type URLPatternCompatible = string | URLPatternInit | URLPattern;
|
|
13622
13726
|
type URLPatternInput = string | URLPatternInit;
|
|
13623
13727
|
type Uint32List = Uint32Array | GLuint[];
|
|
13624
13728
|
type XMLHttpRequestBodyInit = Blob | BufferSource | FormData | URLSearchParams | string;
|
|
@@ -13649,7 +13753,7 @@ type FontFaceSetLoadStatus = "loaded" | "loading";
|
|
|
13649
13753
|
type FrameType = "auxiliary" | "nested" | "none" | "top-level";
|
|
13650
13754
|
type GPUAddressMode = "clamp-to-edge" | "mirror-repeat" | "repeat";
|
|
13651
13755
|
type GPUAutoLayoutMode = "auto";
|
|
13652
|
-
type GPUBlendFactor = "constant" | "dst" | "dst-alpha" | "one" | "one-minus-constant" | "one-minus-dst" | "one-minus-dst-alpha" | "one-minus-src" | "one-minus-src-alpha" | "src" | "src-alpha" | "src-alpha-saturated" | "zero";
|
|
13756
|
+
type GPUBlendFactor = "constant" | "dst" | "dst-alpha" | "one" | "one-minus-constant" | "one-minus-dst" | "one-minus-dst-alpha" | "one-minus-src" | "one-minus-src-alpha" | "one-minus-src1" | "one-minus-src1-alpha" | "src" | "src-alpha" | "src-alpha-saturated" | "src1" | "src1-alpha" | "zero";
|
|
13653
13757
|
type GPUBlendOperation = "add" | "max" | "min" | "reverse-subtract" | "subtract";
|
|
13654
13758
|
type GPUBufferBindingType = "read-only-storage" | "storage" | "uniform";
|
|
13655
13759
|
type GPUBufferMapState = "mapped" | "pending" | "unmapped";
|
|
@@ -13660,7 +13764,7 @@ type GPUCompilationMessageType = "error" | "info" | "warning";
|
|
|
13660
13764
|
type GPUCullMode = "back" | "front" | "none";
|
|
13661
13765
|
type GPUDeviceLostReason = "destroyed" | "unknown";
|
|
13662
13766
|
type GPUErrorFilter = "internal" | "out-of-memory" | "validation";
|
|
13663
|
-
type GPUFeatureName = "bgra8unorm-storage" | "clip-distances" | "core-features-and-limits" | "depth-clip-control" | "depth32float-stencil8" | "dual-source-blending" | "float32-blendable" | "float32-filterable" | "indirect-first-instance" | "primitive-index" | "rg11b10ufloat-renderable" | "shader-f16" | "subgroups" | "texture-compression-astc" | "texture-compression-astc-sliced-3d" | "texture-compression-bc" | "texture-compression-bc-sliced-3d" | "texture-compression-etc2" | "texture-formats-tier1" | "timestamp-query";
|
|
13767
|
+
type GPUFeatureName = "bgra8unorm-storage" | "clip-distances" | "core-features-and-limits" | "depth-clip-control" | "depth32float-stencil8" | "dual-source-blending" | "float32-blendable" | "float32-filterable" | "indirect-first-instance" | "primitive-index" | "rg11b10ufloat-renderable" | "shader-f16" | "subgroups" | "texture-component-swizzle" | "texture-compression-astc" | "texture-compression-astc-sliced-3d" | "texture-compression-bc" | "texture-compression-bc-sliced-3d" | "texture-compression-etc2" | "texture-formats-tier1" | "texture-formats-tier2" | "timestamp-query";
|
|
13664
13768
|
type GPUFilterMode = "linear" | "nearest";
|
|
13665
13769
|
type GPUFrontFace = "ccw" | "cw";
|
|
13666
13770
|
type GPUIndexFormat = "uint16" | "uint32";
|
|
@@ -13716,6 +13820,8 @@ type RequestPriority = "auto" | "high" | "low";
|
|
|
13716
13820
|
type RequestRedirect = "error" | "follow" | "manual";
|
|
13717
13821
|
type ResizeQuality = "high" | "low" | "medium" | "pixelated";
|
|
13718
13822
|
type ResponseType = "basic" | "cors" | "default" | "error" | "opaque" | "opaqueredirect";
|
|
13823
|
+
type RouterSourceEnum = "cache" | "fetch-event" | "network" | "race-network-and-fetch-handler";
|
|
13824
|
+
type RunningStatus = "not-running" | "running";
|
|
13719
13825
|
type SecurityPolicyViolationEventDisposition = "enforce" | "report";
|
|
13720
13826
|
type ServiceWorkerState = "activated" | "activating" | "installed" | "installing" | "parsed" | "redundant";
|
|
13721
13827
|
type ServiceWorkerUpdateViaCache = "all" | "imports" | "none";
|
package/ts5.6/iterable.d.ts
CHANGED
|
@@ -179,6 +179,15 @@ interface IDBObjectStore {
|
|
|
179
179
|
createIndex(name: string, keyPath: string | Iterable<string>, options?: IDBIndexParameters): IDBIndex;
|
|
180
180
|
}
|
|
181
181
|
|
|
182
|
+
interface InstallEvent {
|
|
183
|
+
/**
|
|
184
|
+
* The **`addRoutes()`** method of the InstallEvent interface specifies one or more static routes, which define rules for fetching specified resources that will be used even before service worker startup. This allows you to, for example, bypass a service worker in cases where you always want to fetch a resource from the network or a browser Cache, and avoids the performance overhead of unnecessary service worker cycles.
|
|
185
|
+
*
|
|
186
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/InstallEvent/addRoutes)
|
|
187
|
+
*/
|
|
188
|
+
addRoutes(rules: RouterRule | Iterable<RouterRule>): Promise<void>;
|
|
189
|
+
}
|
|
190
|
+
|
|
182
191
|
interface MessageEvent<T = any> {
|
|
183
192
|
/** @deprecated */
|
|
184
193
|
initMessageEvent(type: string, bubbles?: boolean, cancelable?: boolean, data?: any, origin?: string, lastEventId?: string, source?: MessageEventSource | null, ports?: Iterable<MessagePort>): void;
|
package/ts5.9/index.d.ts
CHANGED
|
@@ -533,8 +533,10 @@ interface GPURenderPipelineDescriptor extends GPUPipelineDescriptorBase {
|
|
|
533
533
|
}
|
|
534
534
|
|
|
535
535
|
interface GPURequestAdapterOptions {
|
|
536
|
+
featureLevel?: string;
|
|
536
537
|
forceFallbackAdapter?: boolean;
|
|
537
538
|
powerPreference?: GPUPowerPreference;
|
|
539
|
+
xrCompatible?: boolean;
|
|
538
540
|
}
|
|
539
541
|
|
|
540
542
|
interface GPUSamplerBindingLayout {
|
|
@@ -554,8 +556,14 @@ interface GPUSamplerDescriptor extends GPUObjectDescriptorBase {
|
|
|
554
556
|
mipmapFilter?: GPUMipmapFilterMode;
|
|
555
557
|
}
|
|
556
558
|
|
|
559
|
+
interface GPUShaderModuleCompilationHint {
|
|
560
|
+
entryPoint: string;
|
|
561
|
+
layout?: GPUPipelineLayout | GPUAutoLayoutMode;
|
|
562
|
+
}
|
|
563
|
+
|
|
557
564
|
interface GPUShaderModuleDescriptor extends GPUObjectDescriptorBase {
|
|
558
565
|
code: string;
|
|
566
|
+
compilationHints?: GPUShaderModuleCompilationHint[];
|
|
559
567
|
}
|
|
560
568
|
|
|
561
569
|
interface GPUStencilFaceState {
|
|
@@ -612,6 +620,7 @@ interface GPUTextureViewDescriptor extends GPUObjectDescriptorBase {
|
|
|
612
620
|
dimension?: GPUTextureViewDimension;
|
|
613
621
|
format?: GPUTextureFormat;
|
|
614
622
|
mipLevelCount?: GPUIntegerCoordinate;
|
|
623
|
+
swizzle?: string;
|
|
615
624
|
usage?: GPUTextureUsageFlags;
|
|
616
625
|
}
|
|
617
626
|
|
|
@@ -660,6 +669,12 @@ interface IDBDatabaseInfo {
|
|
|
660
669
|
version?: number;
|
|
661
670
|
}
|
|
662
671
|
|
|
672
|
+
interface IDBGetAllOptions {
|
|
673
|
+
count?: number;
|
|
674
|
+
direction?: IDBCursorDirection;
|
|
675
|
+
query?: any;
|
|
676
|
+
}
|
|
677
|
+
|
|
663
678
|
interface IDBIndexParameters {
|
|
664
679
|
multiEntry?: boolean;
|
|
665
680
|
unique?: boolean;
|
|
@@ -875,7 +890,12 @@ interface PushSubscriptionChangeEventInit extends ExtendableEventInit {
|
|
|
875
890
|
interface PushSubscriptionJSON {
|
|
876
891
|
endpoint?: string;
|
|
877
892
|
expirationTime?: EpochTimeStamp | null;
|
|
878
|
-
keys?:
|
|
893
|
+
keys?: PushSubscriptionKeys;
|
|
894
|
+
}
|
|
895
|
+
|
|
896
|
+
interface PushSubscriptionKeys {
|
|
897
|
+
auth?: string;
|
|
898
|
+
p256dh?: string;
|
|
879
899
|
}
|
|
880
900
|
|
|
881
901
|
interface PushSubscriptionOptionsInit {
|
|
@@ -997,6 +1017,25 @@ interface ResponseInit {
|
|
|
997
1017
|
statusText?: string;
|
|
998
1018
|
}
|
|
999
1019
|
|
|
1020
|
+
interface RouterCondition {
|
|
1021
|
+
not?: RouterCondition;
|
|
1022
|
+
or?: RouterCondition[];
|
|
1023
|
+
requestDestination?: RequestDestination;
|
|
1024
|
+
requestMethod?: string;
|
|
1025
|
+
requestMode?: RequestMode;
|
|
1026
|
+
runningStatus?: RunningStatus;
|
|
1027
|
+
urlPattern?: URLPatternCompatible;
|
|
1028
|
+
}
|
|
1029
|
+
|
|
1030
|
+
interface RouterRule {
|
|
1031
|
+
condition: RouterCondition;
|
|
1032
|
+
source: RouterSource;
|
|
1033
|
+
}
|
|
1034
|
+
|
|
1035
|
+
interface RouterSourceDict {
|
|
1036
|
+
cacheName?: string;
|
|
1037
|
+
}
|
|
1038
|
+
|
|
1000
1039
|
interface RsaHashedImportParams extends Algorithm {
|
|
1001
1040
|
hash: HashAlgorithmIdentifier;
|
|
1002
1041
|
}
|
|
@@ -6165,6 +6204,12 @@ interface IDBIndex {
|
|
|
6165
6204
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/IDBIndex/getAllKeys)
|
|
6166
6205
|
*/
|
|
6167
6206
|
getAllKeys(queryOrOptions?: IDBValidKey | IDBKeyRange | null, count?: number): IDBRequest<IDBValidKey[]>;
|
|
6207
|
+
/**
|
|
6208
|
+
* The **`getAllRecords()`** method of the IDBIndex interface retrieves all records (including index keys, primary keys, and values) from the index.
|
|
6209
|
+
*
|
|
6210
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/IDBIndex/getAllRecords)
|
|
6211
|
+
*/
|
|
6212
|
+
getAllRecords(options?: IDBGetAllOptions): IDBRequest;
|
|
6168
6213
|
/**
|
|
6169
6214
|
* The **`getKey()`** method of the IDBIndex interface returns an IDBRequest object, and, in a separate thread, finds either the primary key that corresponds to the given key in this index or the first corresponding primary key, if key is set to an IDBKeyRange.
|
|
6170
6215
|
*
|
|
@@ -6347,6 +6392,12 @@ interface IDBObjectStore {
|
|
|
6347
6392
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/IDBObjectStore/getAllKeys)
|
|
6348
6393
|
*/
|
|
6349
6394
|
getAllKeys(queryOrOptions?: IDBValidKey | IDBKeyRange | null, count?: number): IDBRequest<IDBValidKey[]>;
|
|
6395
|
+
/**
|
|
6396
|
+
* The **`getAllRecords()`** method of the IDBObjectStore interface retrieves all records (including primary keys and values) from the object store.
|
|
6397
|
+
*
|
|
6398
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/IDBObjectStore/getAllRecords)
|
|
6399
|
+
*/
|
|
6400
|
+
getAllRecords(options?: IDBGetAllOptions): IDBRequest;
|
|
6350
6401
|
/**
|
|
6351
6402
|
* The **`getKey()`** method of the IDBObjectStore interface returns an IDBRequest object, and, in a separate thread, returns the key selected by the specified query. This is for retrieving specific records from an object store.
|
|
6352
6403
|
*
|
|
@@ -6410,6 +6461,18 @@ declare var IDBOpenDBRequest: {
|
|
|
6410
6461
|
new(): IDBOpenDBRequest;
|
|
6411
6462
|
};
|
|
6412
6463
|
|
|
6464
|
+
/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/IDBRecord) */
|
|
6465
|
+
interface IDBRecord {
|
|
6466
|
+
readonly key: any;
|
|
6467
|
+
readonly primaryKey: any;
|
|
6468
|
+
readonly value: any;
|
|
6469
|
+
}
|
|
6470
|
+
|
|
6471
|
+
declare var IDBRecord: {
|
|
6472
|
+
prototype: IDBRecord;
|
|
6473
|
+
new(): IDBRecord;
|
|
6474
|
+
};
|
|
6475
|
+
|
|
6413
6476
|
interface IDBRequestEventMap {
|
|
6414
6477
|
"error": Event;
|
|
6415
6478
|
"success": Event;
|
|
@@ -6661,6 +6724,25 @@ interface ImportMeta {
|
|
|
6661
6724
|
resolve(specifier: string): string;
|
|
6662
6725
|
}
|
|
6663
6726
|
|
|
6727
|
+
/**
|
|
6728
|
+
* The parameter passed into an install event handler function, the **`InstallEvent`** interface represents an install action that is dispatched on the ServiceWorkerGlobalScope of a ServiceWorker. As a child of ExtendableEvent, it ensures that functional events such as FetchEvent are not dispatched during installation.
|
|
6729
|
+
*
|
|
6730
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/InstallEvent)
|
|
6731
|
+
*/
|
|
6732
|
+
interface InstallEvent extends ExtendableEvent {
|
|
6733
|
+
/**
|
|
6734
|
+
* The **`addRoutes()`** method of the InstallEvent interface specifies one or more static routes, which define rules for fetching specified resources that will be used even before service worker startup. This allows you to, for example, bypass a service worker in cases where you always want to fetch a resource from the network or a browser Cache, and avoids the performance overhead of unnecessary service worker cycles.
|
|
6735
|
+
*
|
|
6736
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/InstallEvent/addRoutes)
|
|
6737
|
+
*/
|
|
6738
|
+
addRoutes(rules: RouterRule | RouterRule[]): Promise<void>;
|
|
6739
|
+
}
|
|
6740
|
+
|
|
6741
|
+
declare var InstallEvent: {
|
|
6742
|
+
prototype: InstallEvent;
|
|
6743
|
+
new(type: string, eventInitDict?: ExtendableEventInit): InstallEvent;
|
|
6744
|
+
};
|
|
6745
|
+
|
|
6664
6746
|
/**
|
|
6665
6747
|
* The **`KHR_parallel_shader_compile`** extension is part of the WebGL API and enables a non-blocking poll operation, so that compile/link status availability (COMPLETION_STATUS_KHR) can be queried without potentially incurring stalls. In other words you can check the status of your shaders compiling without blocking the runtime.
|
|
6666
6748
|
*
|
|
@@ -7422,12 +7504,18 @@ interface Performance extends EventTarget {
|
|
|
7422
7504
|
*
|
|
7423
7505
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/Performance/getEntriesByName)
|
|
7424
7506
|
*/
|
|
7507
|
+
getEntriesByName(name: string, type: "mark"): PerformanceMark[];
|
|
7508
|
+
getEntriesByName(name: string, type: "measure"): PerformanceMeasure[];
|
|
7509
|
+
getEntriesByName(name: string, type: "resource"): PerformanceResourceTiming[];
|
|
7425
7510
|
getEntriesByName(name: string, type?: string): PerformanceEntryList;
|
|
7426
7511
|
/**
|
|
7427
7512
|
* The **`getEntriesByType()`** method returns an array of PerformanceEntry objects currently present in the performance timeline for a given type.
|
|
7428
7513
|
*
|
|
7429
7514
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/Performance/getEntriesByType)
|
|
7430
7515
|
*/
|
|
7516
|
+
getEntriesByType(type: "mark"): PerformanceMark[];
|
|
7517
|
+
getEntriesByType(type: "measure"): PerformanceMeasure[];
|
|
7518
|
+
getEntriesByType(type: "resource"): PerformanceResourceTiming[];
|
|
7431
7519
|
getEntriesByType(type: string): PerformanceEntryList;
|
|
7432
7520
|
/**
|
|
7433
7521
|
* The **`mark()`** method creates a named PerformanceMark object representing a high resolution timestamp marker in the browser's performance timeline.
|
|
@@ -7605,12 +7693,18 @@ interface PerformanceObserverEntryList {
|
|
|
7605
7693
|
*
|
|
7606
7694
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/PerformanceObserverEntryList/getEntriesByName)
|
|
7607
7695
|
*/
|
|
7696
|
+
getEntriesByName(name: string, type: "mark"): PerformanceMark[];
|
|
7697
|
+
getEntriesByName(name: string, type: "measure"): PerformanceMeasure[];
|
|
7698
|
+
getEntriesByName(name: string, type: "resource"): PerformanceResourceTiming[];
|
|
7608
7699
|
getEntriesByName(name: string, type?: string): PerformanceEntryList;
|
|
7609
7700
|
/**
|
|
7610
7701
|
* The **`getEntriesByType()`** method of the PerformanceObserverEntryList returns a list of explicitly observed performance entry objects for a given performance entry type. The list's members are determined by the set of entry types specified in the call to the observe() method. The list is available in the observer's callback function (as the first parameter in the callback).
|
|
7611
7702
|
*
|
|
7612
7703
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/PerformanceObserverEntryList/getEntriesByType)
|
|
7613
7704
|
*/
|
|
7705
|
+
getEntriesByType(type: "mark"): PerformanceMark[];
|
|
7706
|
+
getEntriesByType(type: "measure"): PerformanceMeasure[];
|
|
7707
|
+
getEntriesByType(type: "resource"): PerformanceResourceTiming[];
|
|
7614
7708
|
getEntriesByType(type: string): PerformanceEntryList;
|
|
7615
7709
|
}
|
|
7616
7710
|
|
|
@@ -7757,6 +7851,8 @@ interface PerformanceResourceTiming extends PerformanceEntry {
|
|
|
7757
7851
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/PerformanceResourceTiming/transferSize)
|
|
7758
7852
|
*/
|
|
7759
7853
|
readonly transferSize: number;
|
|
7854
|
+
readonly workerCacheLookupStart: DOMHighResTimeStamp;
|
|
7855
|
+
readonly workerRouterEvaluationStart: DOMHighResTimeStamp;
|
|
7760
7856
|
/**
|
|
7761
7857
|
* The **`workerStart`** read-only property of the PerformanceResourceTiming interface returns a DOMHighResTimeStamp immediately before dispatching the FetchEvent if a Service Worker thread is already running, or immediately before starting the Service Worker thread if it is not already running. If the resource is not intercepted by a Service Worker the property will always return 0.
|
|
7762
7858
|
*
|
|
@@ -8213,6 +8309,12 @@ declare var ReadableStream: {
|
|
|
8213
8309
|
new(underlyingSource: UnderlyingByteSource, strategy?: { highWaterMark?: number }): ReadableStream<Uint8Array<ArrayBuffer>>;
|
|
8214
8310
|
new<R = any>(underlyingSource: UnderlyingDefaultSource<R>, strategy?: QueuingStrategy<R>): ReadableStream<R>;
|
|
8215
8311
|
new<R = any>(underlyingSource?: UnderlyingSource<R>, strategy?: QueuingStrategy<R>): ReadableStream<R>;
|
|
8312
|
+
/**
|
|
8313
|
+
* The **`ReadableStream.from()`** static method returns a ReadableStream from a provided iterable or async iterable object.
|
|
8314
|
+
*
|
|
8315
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableStream/from_static)
|
|
8316
|
+
*/
|
|
8317
|
+
from(asyncIterable: Iterable<any>): ReadableStream;
|
|
8216
8318
|
};
|
|
8217
8319
|
|
|
8218
8320
|
/**
|
|
@@ -8558,7 +8660,7 @@ interface Scheduler {
|
|
|
8558
8660
|
*
|
|
8559
8661
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/Scheduler/postTask)
|
|
8560
8662
|
*/
|
|
8561
|
-
postTask(callback: SchedulerPostTaskCallback
|
|
8663
|
+
postTask<T = any>(callback: SchedulerPostTaskCallback<T>, options?: SchedulerPostTaskOptions): Promise<T>;
|
|
8562
8664
|
/**
|
|
8563
8665
|
* The **`yield()`** method of the Scheduler interface is used for yielding to the main thread during a task and continuing execution later, with the continuation scheduled as a prioritized task (see the Prioritized Task Scheduling API for more information). This allows long-running work to be broken up so the browser stays responsive.
|
|
8564
8666
|
*
|
|
@@ -13349,8 +13451,8 @@ interface ReportingObserverCallback {
|
|
|
13349
13451
|
(reports: Report[], observer: ReportingObserver): void;
|
|
13350
13452
|
}
|
|
13351
13453
|
|
|
13352
|
-
interface SchedulerPostTaskCallback {
|
|
13353
|
-
():
|
|
13454
|
+
interface SchedulerPostTaskCallback<T = any> {
|
|
13455
|
+
(): T | PromiseLike<T>;
|
|
13354
13456
|
}
|
|
13355
13457
|
|
|
13356
13458
|
interface TransformerFlushCallback<O> {
|
|
@@ -13549,7 +13651,7 @@ type AllowSharedBufferSource = ArrayBufferLike | ArrayBufferView<ArrayBufferLike
|
|
|
13549
13651
|
type BigInteger = Uint8Array<ArrayBuffer>;
|
|
13550
13652
|
type BlobPart = BufferSource | Blob | string;
|
|
13551
13653
|
type BodyInit = ReadableStream | XMLHttpRequestBodyInit;
|
|
13552
|
-
type BufferSource =
|
|
13654
|
+
type BufferSource = ArrayBuffer | ArrayBufferView<ArrayBuffer>;
|
|
13553
13655
|
type CSSKeywordish = string | CSSKeywordValue;
|
|
13554
13656
|
type CSSNumberish = number | CSSNumericValue;
|
|
13555
13657
|
type CSSPerspectiveValue = CSSNumericValue | CSSKeywordish;
|
|
@@ -13616,9 +13718,11 @@ type ReadableStreamReadResult<T> = ReadableStreamReadValueResult<T> | ReadableSt
|
|
|
13616
13718
|
type ReadableStreamReader<T> = ReadableStreamDefaultReader<T> | ReadableStreamBYOBReader;
|
|
13617
13719
|
type ReportList = Report[];
|
|
13618
13720
|
type RequestInfo = Request | string;
|
|
13721
|
+
type RouterSource = RouterSourceDict | RouterSourceEnum;
|
|
13619
13722
|
type TexImageSource = ImageBitmap | ImageData | OffscreenCanvas;
|
|
13620
13723
|
type TimerHandler = string | Function;
|
|
13621
13724
|
type Transferable = OffscreenCanvas | ImageBitmap | MessagePort | ReadableStream | WritableStream | TransformStream | ArrayBuffer;
|
|
13725
|
+
type URLPatternCompatible = string | URLPatternInit | URLPattern;
|
|
13622
13726
|
type URLPatternInput = string | URLPatternInit;
|
|
13623
13727
|
type Uint32List = Uint32Array<ArrayBufferLike> | GLuint[];
|
|
13624
13728
|
type XMLHttpRequestBodyInit = Blob | BufferSource | FormData | URLSearchParams | string;
|
|
@@ -13649,7 +13753,7 @@ type FontFaceSetLoadStatus = "loaded" | "loading";
|
|
|
13649
13753
|
type FrameType = "auxiliary" | "nested" | "none" | "top-level";
|
|
13650
13754
|
type GPUAddressMode = "clamp-to-edge" | "mirror-repeat" | "repeat";
|
|
13651
13755
|
type GPUAutoLayoutMode = "auto";
|
|
13652
|
-
type GPUBlendFactor = "constant" | "dst" | "dst-alpha" | "one" | "one-minus-constant" | "one-minus-dst" | "one-minus-dst-alpha" | "one-minus-src" | "one-minus-src-alpha" | "src" | "src-alpha" | "src-alpha-saturated" | "zero";
|
|
13756
|
+
type GPUBlendFactor = "constant" | "dst" | "dst-alpha" | "one" | "one-minus-constant" | "one-minus-dst" | "one-minus-dst-alpha" | "one-minus-src" | "one-minus-src-alpha" | "one-minus-src1" | "one-minus-src1-alpha" | "src" | "src-alpha" | "src-alpha-saturated" | "src1" | "src1-alpha" | "zero";
|
|
13653
13757
|
type GPUBlendOperation = "add" | "max" | "min" | "reverse-subtract" | "subtract";
|
|
13654
13758
|
type GPUBufferBindingType = "read-only-storage" | "storage" | "uniform";
|
|
13655
13759
|
type GPUBufferMapState = "mapped" | "pending" | "unmapped";
|
|
@@ -13660,7 +13764,7 @@ type GPUCompilationMessageType = "error" | "info" | "warning";
|
|
|
13660
13764
|
type GPUCullMode = "back" | "front" | "none";
|
|
13661
13765
|
type GPUDeviceLostReason = "destroyed" | "unknown";
|
|
13662
13766
|
type GPUErrorFilter = "internal" | "out-of-memory" | "validation";
|
|
13663
|
-
type GPUFeatureName = "bgra8unorm-storage" | "clip-distances" | "core-features-and-limits" | "depth-clip-control" | "depth32float-stencil8" | "dual-source-blending" | "float32-blendable" | "float32-filterable" | "indirect-first-instance" | "primitive-index" | "rg11b10ufloat-renderable" | "shader-f16" | "subgroups" | "texture-compression-astc" | "texture-compression-astc-sliced-3d" | "texture-compression-bc" | "texture-compression-bc-sliced-3d" | "texture-compression-etc2" | "texture-formats-tier1" | "timestamp-query";
|
|
13767
|
+
type GPUFeatureName = "bgra8unorm-storage" | "clip-distances" | "core-features-and-limits" | "depth-clip-control" | "depth32float-stencil8" | "dual-source-blending" | "float32-blendable" | "float32-filterable" | "indirect-first-instance" | "primitive-index" | "rg11b10ufloat-renderable" | "shader-f16" | "subgroups" | "texture-component-swizzle" | "texture-compression-astc" | "texture-compression-astc-sliced-3d" | "texture-compression-bc" | "texture-compression-bc-sliced-3d" | "texture-compression-etc2" | "texture-formats-tier1" | "texture-formats-tier2" | "timestamp-query";
|
|
13664
13768
|
type GPUFilterMode = "linear" | "nearest";
|
|
13665
13769
|
type GPUFrontFace = "ccw" | "cw";
|
|
13666
13770
|
type GPUIndexFormat = "uint16" | "uint32";
|
|
@@ -13716,6 +13820,8 @@ type RequestPriority = "auto" | "high" | "low";
|
|
|
13716
13820
|
type RequestRedirect = "error" | "follow" | "manual";
|
|
13717
13821
|
type ResizeQuality = "high" | "low" | "medium" | "pixelated";
|
|
13718
13822
|
type ResponseType = "basic" | "cors" | "default" | "error" | "opaque" | "opaqueredirect";
|
|
13823
|
+
type RouterSourceEnum = "cache" | "fetch-event" | "network" | "race-network-and-fetch-handler";
|
|
13824
|
+
type RunningStatus = "not-running" | "running";
|
|
13719
13825
|
type SecurityPolicyViolationEventDisposition = "enforce" | "report";
|
|
13720
13826
|
type ServiceWorkerState = "activated" | "activating" | "installed" | "installing" | "parsed" | "redundant";
|
|
13721
13827
|
type ServiceWorkerUpdateViaCache = "all" | "imports" | "none";
|
package/ts5.9/iterable.d.ts
CHANGED
|
@@ -179,6 +179,15 @@ interface IDBObjectStore {
|
|
|
179
179
|
createIndex(name: string, keyPath: string | Iterable<string>, options?: IDBIndexParameters): IDBIndex;
|
|
180
180
|
}
|
|
181
181
|
|
|
182
|
+
interface InstallEvent {
|
|
183
|
+
/**
|
|
184
|
+
* The **`addRoutes()`** method of the InstallEvent interface specifies one or more static routes, which define rules for fetching specified resources that will be used even before service worker startup. This allows you to, for example, bypass a service worker in cases where you always want to fetch a resource from the network or a browser Cache, and avoids the performance overhead of unnecessary service worker cycles.
|
|
185
|
+
*
|
|
186
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/InstallEvent/addRoutes)
|
|
187
|
+
*/
|
|
188
|
+
addRoutes(rules: RouterRule | Iterable<RouterRule>): Promise<void>;
|
|
189
|
+
}
|
|
190
|
+
|
|
182
191
|
interface MessageEvent<T = any> {
|
|
183
192
|
/** @deprecated */
|
|
184
193
|
initMessageEvent(type: string, bubbles?: boolean, cancelable?: boolean, data?: any, origin?: string, lastEventId?: string, source?: MessageEventSource | null, ports?: Iterable<MessagePort>): void;
|