npm.io
2.0.6 • Published 2 years ago

@types/promise.prototype.finally

Licence
MIT
Version
2.0.6
Deps
0
Size
4 kB
Vulns
0
Weekly
0
Stars
51.4K

Installation

npm install --save @types/promise.prototype.finally

Summary

This package contains type definitions for promise.prototype.finally (https://github.com/es-shims/promise.prototype.finally).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/promise.prototype.finally.

index.d.ts

declare global {
    interface Promise<T> {
        finally<U>(onFinally?: () => U | PromiseLike<U>): Promise<T>;
    }
}

export = promiseFinally;

declare function promiseFinally<T, U>(promise: Promise<T>, onFinally?: () => U | PromiseLike<U>): Promise<T>;
declare namespace promiseFinally {
    function shim(): void;
}

Additional Details

  • Last updated: Tue, 07 Nov 2023 0939 GMT
  • Dependencies: none

Credits

These definitions were written by Slava Shpitalny, BendingBender, and Jordan Harband.