Skip to content

scrollend event #560

Answered by idiotWu
enne87 asked this question in Q&A
Feb 29, 2024 · 1 comments · 1 reply
Discussion options

You must be logged in to vote

A workaround is to register a debounced listener:

let scrollEndTimer;

scrollbar.addListener(() => {
  clearTimeout(scrollEndTimer);
  scrollEndTimer = setTimeout(() => {
    console.log('scrollend');
  }, 100); // any timeout > 16.7ms should possibly work
});

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@enne87
Comment options

Answer selected by enne87
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants