Releases: lsphillips/you-are-cancelled
Releases · lsphillips/you-are-cancelled
v2.0.1
v2.0.0
Added
- Introduced
CancellationToken#toAbortSignal()
that will return anAbortSignal
object that reflects the cancellation state of the token. - Introduced
CancellationToken#reason
that will reflect the reason for why the cancellation was requested.
Changed
- Replaced
CancellationToken#canBeCancelled
withCancellationToken#isCancelable
. - Cancellation callbacks will be cleaned up after they are executed during a cancellation request.
- Cancellation callbacks that will be executed are determined before any are executed. This means attempting to deregister a cancellation callback during a cancellation request will be ignored.
- Updated
CancellationToken#register()
to return the callback function being registered.
v1.3.0
Changed
- The UMD version of this module now exposes itself using the name
you-are-cancelled
.
v1.2.0
Added
- Introduced ESM and UMD versions of this module, each with an ES5 version for browser environments.
Changed
- This module now exports minified single file entry points, making this package much more lightweight.
v1.1.0
Changed
- Support for Node.js version
10.x.x
has been dropped.
Fixed
- The TypeScript definition for the
CancellationToken#register()
method now accepts the correct callback type.
v1.0.1
Fixed
- The TypeScript definition for the
CancellationToken
is now exposed as a class. - The TypeScript definitions now include
CancellationToken.None
.
v1.0.0
The initial public release.