Sign in
Log inSign up

componentDidUpdate() situation

Tonny Hideyori's photo
Tonny Hideyori
·Jan 9, 2019

i have a component which update the backend after an action in frontend.I used the componentDidmount() but it fetched half of the data unless i refresh physically. so i decided to use componentDidUpdate() it updated instantly but the problem is that method keeps on calling back-end for data in every second it don't want that . i want the back end to be called after an action,then update the front-end is there any react life cycle method apart from componentDidMount() or componentDidUpdate()

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