Skip to content

@loontail/minecraft-kit v0.8.14 / EventType

Type alias: EventType

ts
type EventType: typeof EventTypes[keyof typeof EventTypes];

Literal type of the type discriminator of a ProgressEvent.

Example

ts
import { EventTypes, type EventType } from "@loontail/minecraft-kit";

const interesting = new Set<EventType>([EventTypes.DOWNLOAD_FAILED, EventTypes.INTEGRITY_MISMATCH]);
const onEvent = (e: { type: EventType }) => { if (interesting.has(e.type)) console.warn(e); };

Source

src/types/events.ts:54

MIT License