We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
undefined
null
1 parent 22aa51d commit 5491871Copy full SHA for 5491871
src/runtime/internal/lifecycle.ts
@@ -34,9 +34,9 @@ type UnionToIntersection<U> = (U extends any ? (k: U) => void : never) extends (
34
type ExtractObjectValues<Object extends Record<any, any>> = Object[keyof Object]
35
36
type ConstructDispatchFunction<EventMap extends Record<string, any>, EventKey extends keyof EventMap> =
37
- EventMap[EventKey] extends never
+ EventMap[EventKey] extends never | null
38
? (type: EventKey) => void
39
- : undefined extends EventMap[EventKey]
+ : null extends EventMap[EventKey]
40
? (type: EventKey, detail?: EventMap[EventKey]) => void
41
: (type: EventKey, detail: EventMap[EventKey]) => void
42
0 commit comments