diff --git a/src/calendar_icon.jsx b/src/calendar_icon.jsx index 01f21dd0e..20961ce27 100644 --- a/src/calendar_icon.jsx +++ b/src/calendar_icon.jsx @@ -1,7 +1,7 @@ import React from "react"; import PropTypes from "prop-types"; -const CalendarIcon = ({ icon, className }) => { +const CalendarIcon = ({ icon, className = "" }) => { const defaultClass = "react-datepicker__calendar-icon"; if (React.isValidElement(icon)) { @@ -36,8 +36,4 @@ CalendarIcon.propTypes = { className: PropTypes.string, }; -CalendarIcon.defaultProps = { - className: "", -}; - export default CalendarIcon;