Skip to main content
Journey Uncommon Logo
JourneyUncommon
mediumTypeScriptfunction overloadsSingle-choice MCQ

Inside the callback passed to `on("click", ...)`, what is the type of the parameter `e`?

function on(event: "click", cb: (e: MouseEvent) => void): void; function on(event: "key", cb: (e: KeyboardEvent) => void): void; function on(event: string, cb: (e: any) => void): void {} on("click", (e) => { /* e is ... ? */ });