@types/serviceworker 0.0.43 → 0.0.44

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.
Files changed (3) hide show
  1. package/README.md +1 -1
  2. package/index.d.ts +8 -4
  3. package/package.json +1 -1
package/README.md CHANGED
@@ -28,4 +28,4 @@ This project does not respect semantic versioning as almost every change could p
28
28
 
29
29
  ## Deploy Metadata
30
30
 
31
- You can read what changed in version 0.0.43 at https://github.com/microsoft/TypeScript-DOM-lib-generator/releases/tag/%40types%2Fserviceworker%400.0.43.
31
+ You can read what changed in version 0.0.44 at https://github.com/microsoft/TypeScript-DOM-lib-generator/releases/tag/%40types%2Fserviceworker%400.0.44.
package/index.d.ts CHANGED
@@ -956,6 +956,7 @@ declare var CustomEvent: {
956
956
 
957
957
  /** An abnormal event (called an exception) which occurs as a result of calling a method or accessing a property of a web API. */
958
958
  interface DOMException extends Error {
959
+ /** @deprecated */
959
960
  readonly code: number;
960
961
  readonly message: string;
961
962
  readonly name: string;
@@ -2773,6 +2774,7 @@ interface ServiceWorkerGlobalScope extends WorkerGlobalScope {
2773
2774
  onnotificationclose: ((this: ServiceWorkerGlobalScope, ev: NotificationEvent) => any) | null;
2774
2775
  onpush: ((this: ServiceWorkerGlobalScope, ev: PushEvent) => any) | null;
2775
2776
  readonly registration: ServiceWorkerRegistration;
2777
+ readonly serviceWorker: ServiceWorker;
2776
2778
  skipWaiting(): Promise<void>;
2777
2779
  addEventListener<K extends keyof ServiceWorkerGlobalScopeEventMap>(type: K, listener: (this: ServiceWorkerGlobalScope, ev: ServiceWorkerGlobalScopeEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
2778
2780
  addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
@@ -5116,8 +5118,8 @@ interface WindowOrWorkerGlobalScope {
5116
5118
  readonly performance: Performance;
5117
5119
  atob(data: string): string;
5118
5120
  btoa(data: string): string;
5119
- clearInterval(id?: number): void;
5120
- clearTimeout(id?: number): void;
5121
+ clearInterval(id: number | undefined): void;
5122
+ clearTimeout(id: number | undefined): void;
5121
5123
  createImageBitmap(image: ImageBitmapSource, options?: ImageBitmapOptions): Promise<ImageBitmap>;
5122
5124
  createImageBitmap(image: ImageBitmapSource, sx: number, sy: number, sw: number, sh: number, options?: ImageBitmapOptions): Promise<ImageBitmap>;
5123
5125
  fetch(input: RequestInfo | URL, init?: RequestInit): Promise<Response>;
@@ -5208,6 +5210,7 @@ declare var WritableStream: {
5208
5210
 
5209
5211
  /** This Streams API interface represents a controller allowing control of a WritableStream's state. When constructing a WritableStream, the underlying sink is given a corresponding WritableStreamDefaultController instance to manipulate. */
5210
5212
  interface WritableStreamDefaultController {
5213
+ readonly signal: AbortSignal;
5211
5214
  error(e?: any): void;
5212
5215
  }
5213
5216
 
@@ -5456,6 +5459,7 @@ declare var onnotificationclick: ((this: ServiceWorkerGlobalScope, ev: Notificat
5456
5459
  declare var onnotificationclose: ((this: ServiceWorkerGlobalScope, ev: NotificationEvent) => any) | null;
5457
5460
  declare var onpush: ((this: ServiceWorkerGlobalScope, ev: PushEvent) => any) | null;
5458
5461
  declare var registration: ServiceWorkerRegistration;
5462
+ declare var serviceWorker: ServiceWorker;
5459
5463
  declare function skipWaiting(): Promise<void>;
5460
5464
  /** Dispatches a synthetic event event to target and returns true if either event's cancelable attribute value is false or its preventDefault() method was not invoked, and false otherwise. */
5461
5465
  declare function dispatchEvent(event: Event): boolean;
@@ -5486,8 +5490,8 @@ declare var origin: string;
5486
5490
  declare var performance: Performance;
5487
5491
  declare function atob(data: string): string;
5488
5492
  declare function btoa(data: string): string;
5489
- declare function clearInterval(id?: number): void;
5490
- declare function clearTimeout(id?: number): void;
5493
+ declare function clearInterval(id: number | undefined): void;
5494
+ declare function clearTimeout(id: number | undefined): void;
5491
5495
  declare function createImageBitmap(image: ImageBitmapSource, options?: ImageBitmapOptions): Promise<ImageBitmap>;
5492
5496
  declare function createImageBitmap(image: ImageBitmapSource, sx: number, sy: number, sw: number, sh: number, options?: ImageBitmapOptions): Promise<ImageBitmap>;
5493
5497
  declare function fetch(input: RequestInfo | URL, init?: RequestInit): Promise<Response>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@types/serviceworker",
3
- "version": "0.0.43",
3
+ "version": "0.0.44",
4
4
  "description": "Types for the global scope of Service Workers",
5
5
  "license": "MIT",
6
6
  "contributors": [],