react-md icon indicating copy to clipboard operation
react-md copied to clipboard

[DatePicker] - Add a friendlier formatter for DatePicker

Open thaithcock opened this issue 8 years ago • 1 comments

Currently, you need to use the Intl.DateTimeFormat for formatting dates in the DatePicker. This is a little clunky, and passing a custom function into the DateTimeFormat prop doesn't quite work.

It would be good if we could more easily and reliably pass in a formatter prop function (probably that passes in a Date) to the DatePicker to achieve desired results.

thaithcock avatar Mar 09 '17 21:03 thaithcock

Just a reminder to when someone (or me) picks this up.. The main problem with a custom formatted is needing the ability to extract the year, weekday, and date from the time. See DatePickerHeader and CalendarHeader.

mlaursen avatar Mar 16 '17 15:03 mlaursen