コンテンツにスキップ
日本語

KindOf

このコンテンツはまだ日本語訳がありません。

KindOf<TEvent> = TEvent extends object ? TKind : string

Defined in: src/EventKey.ts:34

The kind of an event type — or plain string when the type carries none, which is what a class channel and an unparameterised call both land on.

Its job is to make the kind checkable against the event type rather than merely typed as a string, so that EventKey.of<UserLoggedInEvent>('user-loged-in') is a compile error rather than a subscription that quietly never matches.

TEvent