Warning: Failed prop type: Invalid prop value supplied to 'DateTimePicker.
See original GitHub issueI’m having like 25 errors and the whole app is crashing when I’m triying to change the event starting hour. Every time I got this :
Warning: Failed prop type: Invalid prop value supplied to 'DateTimePicker.
Warning: Failed prop type: Invalid prop minDate of type object supplied to DateTimePicker, expected instance of Date
Warning: Failed prop type: Invalid prop value supplied to DateTimeInput.
Warning: Failed prop type: Invalid prop value supplied to Calendar
.- `Warning: Failed prop type: Invalid prop value supplied to Clock``. …
I will be grateful if someone can help me.
Issue Analytics
- State:
- Created 2 years ago
- Reactions:1
- Comments:5 (1 by maintainers)
Top Results From Across the Web
How can I fix the DatePicker Invalid prop value of type string ...
Warning : Failed prop type: Invalid prop value of type String supplied to DatePicker , expected instance of Date . in DatePicker.
Read more >Invalid prop `value` of type `string` supplied to `TimePicker ...
Warning : Failed prop type: Invalid prop `value` of type `string` supplied to `TimePicker`, expected `object`.
Read more >Failed prop type: Invalid prop
When an invalid value is passed for a prop, a warning is displayed on the JavaScript console. If default props are set for...
Read more >Warning: Failed prop type: Invalid prop `children` supplied to ...
Warning : Failed prop type: Invalid prop `children` supplied to `ForwardRef(Typography)`, expected a ReactNode. */<Typography key={item.id}>
Read more >Invalid prop 'value' of type 'number' supplied to 'TextInput'
This post is about the Warning: Invalid prop 'value' of type 'number' supplied to 'TextInput', expected 'string'. You will see this warning while...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Indeed I was on 3.4.1, upgrading to 3.4.2 fixed the issue for me. Thanks.
I had the same problem, I am using redux instead of the react
useState
hook.I think the trick is to pass the new Date instance.
So instead of doing this:
... value={selectedTask.due_date ?? new Date()}
I am doing this now and it works:If anyone still needs it. Cheers! 😃