EMAddOf<X>
typeReads the event map a spec contributes, or {} when it declares none.
Only a branded spec widens the event map. An unbranded object literal contributes
{},
which is today's behaviour and therefore always safe.Definition
type
type EMAddOf<X> = X extends { ~yoltraEventMap: (em: E) => unknown } ? E extends EventMapBase ? E : EmptyEventMap : EmptyEventMapX extends { ~yoltraEventMap: (em: E) => unknown } ? E extends EventMapBase ? E : EmptyEventMap : EmptyEventMap
Type parameters
| Name | Type | Description |
|---|---|---|
X | — |