componentDidUpdate
State나 Props가 업데이트 될 때마다 실행되는 함수
Last updated
Was this helpful?
State나 Props가 업데이트 될 때마다 실행되는 함수
Last updated
Was this helpful?
Was this helpful?
componentDidUpdate는 componentDidMount와 같이 render메소드가 수행되고 브라우저에 HTML형태로 렌더링된 시점 이후에 동작하는 점은 같습니다. 다만 다른 점은 componentDidUpdate는 state나 props가 업데이트 되었을 때에만 수행된다는 점 입니다. 다른 부분은 같습니다.