Executes at most once per limit ms: immediately on the leading edge by default, and once more on the trailing edge if further calls arrived.
limit
const update = throttle(() => refreshVisibleRange(), 100);const trailingOnly = throttle(refresh, 100, { leading: false }); Copy
const update = throttle(() => refreshVisibleRange(), 100);const trailingOnly = throttle(refresh, 100, { leading: false });
Executes at most once per
limitms: immediately on the leading edge by default, and once more on the trailing edge if further calls arrived.