Because of the use of the text string and parseInt() to get the date value from the calendar, rome was breaking when localized to a system that does not use western-arabic numerals [0, 1, 2, 3...].
By adding the moment.date() value to a custom attributes tag, data-date, we can be sure that the value returned will always be the correct date value.
Because of the use of the text string and
parseInt()
to get the date value from the calendar, rome was breaking when localized to a system that does not use western-arabic numerals [0, 1, 2, 3...].By adding the
moment.date()
value to a custom attributes tag,data-date
, we can be sure that the value returned will always be the correct date value.