Warning: Accessing PropTypes via the main React package is deprecated. Use the prop-types package from npm instead. : import PropTypes from 'prop-types';