Installation
npm install --save @types/ee-first
Summary
This package contains type definitions for ee-first (https://github.com/jonathanong/ee-first).
Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/ee-first.
import { EventEmitter } from "events";
export = first;
declare function first<TEmitter extends EventEmitter>(
eventSpec: Array<[TEmitter, ...string[]]>,
listener: first.Listener<TEmitter>,
): first.Thunk<TEmitter>;
declare namespace first {
type Listener<TEmitter extends EventEmitter> = (
err: any,
ee: TEmitter,
event: string[],
args: any[],
) => void;
interface Thunk<TEmitter extends EventEmitter> {
(listener: Listener<TEmitter>): void;
cancel(): void;
}
}
Additional Details
- Last updated: Wed, 18 Oct 2023 01:17:34 GMT
- Dependencies: @types/node
Credits
These definitions were written by BendingBender.