Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

393
Views
How to use element.scrollIntoView as a promise or observable?

I'm using

tab_element.scrollIntoView({
        behavior:'smooth',
        block: 'center',
});

to scroll the element at the center
but immediately after this, I need to call router.navigate
This is causing the scroll to be interrupted,
so my solution is to do the navigation after the scrolling is finished.
Is there a way that I can get a promise or an observable which can be used to call a function after scroll completes?

about 4 years ago Ā· Juan Pablo Isaza
1 answers
Answer question

0

I did not find solution so far šŸ˜” There is no native option to get any callback after scroll finishes.. you can only find solutions which hooks on scroll event like this one https://stackoverflow.com/a/51142522/861615

Maybe in few years: https://github.com/w3c/csswg-drafts/issues/3744 šŸ¤·ā€ā™‚ļø

about 4 years ago Ā· Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
Ā© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!