Date-picker opening keyboard on change event

Working on hybrid meteor app and using datepicker to show dates in format MM-DD-YYYY. As datepicker works on input type=‘text’ and meteor changes all this to cordova apk which results in whenever I focus in datepicker input it is not opening mobile phones calender but datepicker’s calender and also opening keyboard as it is of type=‘text’, which is right behaviour I guess but I do not want that keyboard to open.

If I use input type=“date” and will not use datepicker then mobile apk will open native calender but here format I need which is MM-DD-YYYY is not possible.

What should I do?? Thanks in advance!

I think you’re on the right track. You’ll be doing something like “if Cordova, show just input=date; otherwise, show ‘datepicker’.” What if you just get the value from the input when it’s in Cordova mode, and then reformat it to the date format you need yourself?

if cordova : Also need to display what user has chose and display value should be MM-DD-YYYY which input type=“date” is not accepting/displaying.

So for time being I am using date-picker only because it is providing me the format MM-DD-YYYY, to prevent the keyboard from opening as it is input type=“text”, have added extra attribute i.e readOnly=“true”.

Really appreciate your help.