abort-controller
Advanced tools
Comparing version 2.0.1 to 2.0.2
@@ -1,9 +0,9 @@ | ||
import { EventTarget } from 'event-target-shim'; | ||
import { EventTarget } from "event-target-shim" | ||
export declare type Events = { | ||
abort: any; | ||
}; | ||
export declare type EventAttributes = { | ||
onabort: any; | ||
}; | ||
type Events = { | ||
abort: any | ||
} | ||
type EventAttributes = { | ||
onabort: any | ||
} | ||
/** | ||
@@ -13,11 +13,11 @@ * The signal class. | ||
*/ | ||
export declare class AbortSignal extends EventTarget<Events, EventAttributes> { | ||
/** | ||
* AbortSignal cannot be constructed directly. | ||
*/ | ||
constructor(); | ||
/** | ||
* Returns `true` if this `AbortSignal`'s `AbortController` has signaled to abort, and `false` otherwise. | ||
*/ | ||
readonly aborted: boolean; | ||
declare class AbortSignal extends EventTarget<Events, EventAttributes> { | ||
/** | ||
* AbortSignal cannot be constructed directly. | ||
*/ | ||
constructor() | ||
/** | ||
* Returns `true` if this `AbortSignal`"s `AbortController` has signaled to abort, and `false` otherwise. | ||
*/ | ||
readonly aborted: boolean | ||
} | ||
@@ -28,15 +28,18 @@ /** | ||
*/ | ||
export default class AbortController { | ||
/** | ||
* Initialize this controller. | ||
*/ | ||
constructor(); | ||
/** | ||
* Returns the `AbortSignal` object associated with this object. | ||
*/ | ||
readonly signal: AbortSignal; | ||
/** | ||
* Abort and signal to any observers that the associated activity is to be aborted. | ||
*/ | ||
abort(): void; | ||
} | ||
declare class AbortController { | ||
/** | ||
* Initialize this controller. | ||
*/ | ||
constructor() | ||
/** | ||
* Returns the `AbortSignal` object associated with this object. | ||
*/ | ||
readonly signal: AbortSignal | ||
/** | ||
* Abort and signal to any observers that the associated activity is to be aborted. | ||
*/ | ||
abort(): void | ||
} | ||
export default AbortController | ||
export { AbortController, AbortSignal } |
{ | ||
"name": "abort-controller", | ||
"version": "2.0.1", | ||
"version": "2.0.2", | ||
"description": "An implementation of WHATWG AbortController interface.", | ||
@@ -63,3 +63,3 @@ "main": "dist/abort-controller", | ||
"build:rollup": "rollup -c", | ||
"build:dts": "dts-bundle-generator -o dist/abort-controller.d.ts src/abort-controller.ts", | ||
"build:dts": "dts-bundle-generator -o dist/abort-controller.d.ts src/abort-controller.ts && ts-node scripts/fix-dts", | ||
"test": "run-s -s lint test:*", | ||
@@ -66,0 +66,0 @@ "test:mocha": "nyc mocha test/*.ts", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
74932
349