노마드코더 강의_React #2
import React from "react"; import PropTypes from "prop-types"; function Food({ name, picture, rating }) { return ( i like {name} {rating}/5.0 ); } const foodILike = [ { id: 1, name: "kimchi", rating: 5, image: "https://djlib.sen.go.kr/djlib/index.do", }, { id: 2, rating: 4.9, name: "samgyup", image: "https://djlib.sen.go.kr/djlib/index.do", }, ]; Food.propTypes = { name: PropTypes.string.isRequi..
CODING/React.js
2020. 6. 12. 22:27