Skip to content

Implement debouncing for scheduleScan in autoLoadMoreComments#348

Open
iwiznia wants to merge 1 commit into
mainfrom
iwiznia-debouncecomments
Open

Implement debouncing for scheduleScan in autoLoadMoreComments#348
iwiznia wants to merge 1 commit into
mainfrom
iwiznia-debouncecomments

Conversation

@iwiznia
Copy link
Copy Markdown
Contributor

@iwiznia iwiznia commented May 21, 2026

Debounce the scheduleScan function to limit execution frequency.

I tried to add console.log to see the debounce in action, but for some reason I could not see any logs (even though code was running). I think it should work anyway...

Debounce the scheduleScan function to limit execution frequency.
@iwiznia iwiznia requested a review from tgolen May 21, 2026 15:47
@iwiznia iwiznia self-assigned this May 21, 2026
@tgolen
Copy link
Copy Markdown
Contributor

tgolen commented May 21, 2026

I tested this out on rust-lang/rfcs#2544... It did not seem to be working. I didn't have any issues with console.log() though. I added a log to the scan function, and it only fired once.

For this screenshot, I loaded the page, scrolled down to the first "load more..." and clicked on it once. The "scan" log only fired when the page loaded though.

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants