Sign in
Log inSign up

How can I stop processing a function before it completes?

Rahul Bisht's photo
Rahul Bisht
·Apr 10, 2018

I've two tabs on a webpage. When a user switches the tab, it displays its respective layout and it performs some tasks. If a user switches the tab back to one then it becomes slow and it is very visible on the webpage.

So, how can I stop any processing of the respective tab if a user switches tab very quickly?

Hassle-free blogging platform that developers and teams love.
  • Docs by Hashnode
    New
  • Blogs
  • AI Markdown Editor
  • GraphQL APIs
  • Open source Starter-kit

© Hashnode 2024 — LinearBytes Inc.

Privacy PolicyTermsCode of Conduct