- throttle<T>(func, wait, options?): ThrottleFunc<T>
Type Parameters
T extends ((...args) => any)
Parameters
func: T
wait: number
options: {
leading?: boolean;
trailing?: boolean;
} = {}
Optional
leading?: boolean
Optional
trailing?: boolean
Returns ThrottleFunc<T>
EN: Throttle, used to limit the frequency of function execution over time.
ZH: 节流,用于限制函数在一段时间内的执行频率。
Usage:
Reference: Lodash