STUDYING/React
[React] class에서 props로 부모와 자식 간의 데이터를 교환해보자
sustronaut
2022. 6. 4. 01:06
class에선 this를 이용해 데이터를 교환한다
<button onClick={() => this.props.setData("data from child")}>
send data to parent
</button>
- 참고 자료
https://any-ting.tistory.com/8
[React Class] Component Props와 State 사용방법(데이터 전달)
- 지난 시간 지난 시간에 React라는 기술에 대해서 간단하게 설명을 하고, 프로젝트 component를 활용하는 시간을 갖었습니다. 혹시 Component에 대한 개념에 익숙하지 않으시면 제가 올린 글을 한번 읽
any-ting.tistory.com