-
Notifications
You must be signed in to change notification settings - Fork 25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
debounce function #164
Comments
We have an open PR (#128) that addresses this by adding a |
@SingAurora The PR was merged. Here's an example of how to use the const genericFunction = () => {
console.log("This function is called immediately when leading is true.");
};
const debouncedFunc = _.debounce({ delay: 5000, leading: true }, genericFunction); |
Thank you so much for the great open source project
…------------------ 原始邮件 ------------------
发件人: "radashi-org/radashi" ***@***.***>;
发送时间: 2024年8月15日(星期四) 中午1:02
***@***.***>;
***@***.******@***.***>;
主题: Re: [radashi-org/radashi] debounce function (Issue #164)
@SingAurora The PR was merged. Here's an example of how to use the leading option to trigger the function immediately on the first call:
const genericFunction = () => { console.log("This function is called immediately when leading is true."); }; const debouncedFunc = _.debounce({ delay: 5000, leading: true }, genericFunction);
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you were mentioned.Message ID: ***@***.***>
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The debounce function is run at the end of the time window, there is no way to start running in the time window.
The text was updated successfully, but these errors were encountered: