Open dlgustn555 opened 7 years ago
React Compoents는 props를 통해 React Element에 임의로 input된 데이터를 접근할 수 있고, 화면에 그릴 ReactElement를 리턴한다.
1번 또는 2번 방식으로 사용 가능!! 하지만,
map() 안에서 사용되어지는 컨포넌트에는 key를 항상 필요로 한다!!
sometingList.map((item) => (
<Item key={item.toString()} value={item} />
));