Open SharmaHarsh7 opened 7 years ago
Please create a plunker example for this. Without a reproducible example, it's hard to tackle the problem.
It is working fine with plunker but giving error on my machine when I follow the exact same steps mention by you on GIT and in Plunker.
Following is the code I am using:
And this is the error:
Also If I apply date-format attribute, everything goes fine but I don't see any update in the model bind to the control. Apply the code:
Selected a date:
The control is blank:
It looks like the plunker and the steps you provided on GIT are outdated and not updated to the latest version on the control.
Could you please suggest any way to get rid of this issue.
Thanks. Harsh
i am also getting same issue while setting date-format..
Same thing happening for me, the value of the datetime field becomes null on applying the date-format attribute. (Using moment.js, the parse-format attribute is working fine though)
I was facing this issue and it appears to be a bug with NPM not including moment.locale This is why it works in Plunkr, because you are using the CDN
My fix was to directly require("moment/min/locales.min") in my app.module.ts
Hope this helps someone
Hi,
I am using this control in my angular2 application which is based on reactive form approach.
It is working fine when I used the default code as mentioned on your plunker but when I apply date-format attribute it is not showing anything in the text box.
It is showing calendar and allowing me to change the date but the date is not in being display in the text box.
Thanks, Harsh