and my date format is dd MMM yyyy.
When I click a date on datepicker on the 5th month, it's always return 5ei.
and if i click a date on 8th,10th,or 12th month, it's always set to new Date() when i reopened the datepicker component,
example ->
const date = new Date('20 Agu 2017');
return NaN, it's because of
parse (str) {
if (str === undefined || str === null) { str = this.val }
let date = str.length === 10 && (this.format === 'dd-MM-yyyy' || this.format === 'dd/MM/yyyy') ?
new Date(str.substring(6, 10), str.substring(3, 5)-1, str.substring(0, 2)) :
new Date(str)
return isNaN(date.getFullYear()) ? new Date() : date
},
This is my lang config ->
and my date format is
dd MMM yyyy
. When I click a date on datepicker on the 5th month, it's always return 5ei.and if i click a date on 8th,10th,or 12th month, it's always set to new Date() when i reopened the datepicker component,
example ->
return
NaN
, it's because ofI think need momentjs integration