Installation
npm install --save @types/npm-whoami
Summary
This package contains type definitions for npm-whoami (https://github.com/jamestalmage/npm-whoami#readme).
Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/npm-whoami.
index.d.ts
export = whoami;
declare function whoami(callback: whoami.WhoamiCallback, opts?: whoami.WhoamiOptions): void;
declare namespace whoami {
interface WhoamiCallback {
(err: Error, username: undefined): void;
(err: null, username: string): void;
}
type WhoamiOptions = number | string | BothOptions;
interface BothOptions {
registry?: string;
timeout?: number;
}
function sync(opts: WhoamiOptions): string | undefined;
}
Additional Details
- Last updated: Tue, 07 Nov 2023 09:09:39 GMT
- Dependencies: none
Credits
These definitions were written by Josh Goldberg.