kevinoleary19 / Angular-2-Datepicker

A minimalist datepicker inspired by Google's material design
70 stars 71 forks source link

Date Format #94

Open Cris13 opened 7 years ago

Cris13 commented 7 years ago

The default date format it says to be YYYY-MM-DD, although the date is always displayed using "/" and not "-". Is there a way of changing it?

ilyakrasnov commented 7 years ago

I've come across this issue as well. Momentjs was introduced in this pull request, so you can define your own date formats using: dateFormat="YYYY-MM-DD" or something else.

However the npm package is still not updated. We downloaded the plugin directly from github. Change the respective package.json line to be:

"angular2-material-datepicker": "git+https://git@github.com/koleary94/Angular-2-Datepicker.git",

Hope it helps.