mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-07-20 19:46:32 +08:00
chore: skip type check for low quality codes
This commit is contained in:
@@ -1,8 +1,10 @@
|
||||
// eslint-disable-next-line @typescript-eslint/ban-types
|
||||
export function debounce(fn: Function, timeout: number) {
|
||||
let timeoutId: any;
|
||||
|
||||
return function (this: any) {
|
||||
clearTimeout(timeoutId);
|
||||
// eslint-disable-next-line prefer-rest-params
|
||||
timeoutId = setTimeout(() => fn.apply(this, arguments), timeout);
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user