mirror of
https://github.com/youzan/vant.git
synced 2025-10-19 01:54:48 +00:00
types: improve event target typing
This commit is contained in:
@@ -20,7 +20,7 @@ if (!isServer) {
|
||||
}
|
||||
|
||||
export function on(
|
||||
target: HTMLElement | Document | Window,
|
||||
target: EventTarget,
|
||||
event: string,
|
||||
handler: EventHandler,
|
||||
passive = false
|
||||
@@ -35,7 +35,7 @@ export function on(
|
||||
}
|
||||
|
||||
export function off(
|
||||
target: HTMLElement | Document | Window,
|
||||
target: EventTarget,
|
||||
event: string,
|
||||
handler: EventHandler
|
||||
) {
|
||||
|
Reference in New Issue
Block a user