Without using class, how do I use PropTypes in functional stateless component of react?
export const Header = (props) => ( hi )
It's done the same way you do with Class Based Components
import PropTypes from "prop-types"; const = function_name => {} function_name.propTypes = { prop_name : PropTypes.number . . . . . . . . . . . . . . }
Hope This Helps !