📅  最后修改于: 2022-03-11 15:01:14.592000             🧑  作者: Mango
import PropTypes from 'prop-types';
class Greeting extends React.Component {
render() {
return (
Hello, {this.props.name}
);
}
}
Greeting.propTypes = {
name: PropTypes.string
};