Reputation: 1
I get error when I using react-flatpickr, error return: Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) but got: object.
here is my code
import Flatpickr from "react-flatpickr";
const CourseList= (props) => {
...
return(
<>
...
<Flatpickr />
...
</>
)
}
export default CourseList;
if anyone have experienced the same problem and have found a solution or have other alternative ways, please help me to solve this problem. Many thanks!!
I've tried to change:
import Flatpickr from "react-flatpickr";
to
import { Flatpickr } from "react-flatpickr";
but not working.
Upvotes: 0
Views: 177