types(@vant/lazyload): add $Lazyload typing

This commit is contained in:
chenjiahan
2021-09-24 10:48:24 +08:00
committed by neverland
parent 8fbeb6a9c3
commit 3ad17abd52
3 changed files with 13 additions and 76 deletions
+10
View File
@@ -43,3 +43,13 @@ export declare type LazyloadOptions = {
export declare const Lazyload: {
install(app: App, options?: LazyloadOptions): void;
};
declare module '@vue/runtime-core' {
interface ComponentCustomProperties {
$Lazyload: {
$on: (event: string, handler: Callback) => void;
$off: (event: string, handler?: Callback) => void;
$once: (event: string, handler: Callback) => void;
};
}
}