Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Date formatting on ISO Strings is lost #26

Open
nczeranka opened this issue Aug 20, 2019 · 0 comments
Open

Date formatting on ISO Strings is lost #26

nczeranka opened this issue Aug 20, 2019 · 0 comments

Comments

@nczeranka
Copy link

Current version of i18n mananger (1.2.8) is running in an error when trying to format dates provided as ISO string representation - e.g. '2019-08-20T04:00:00.000Z'. (Not an unusual requirement when dealing with JSON data.)

TypeError: dateObj.getTime is not a function
at Object.addMilliseconds (/home/node/sales-invoice/node_modules/@opuscapita/i18n/lib/external_modules/date-and-time.js:226:29)
at Object.addMinutes (/home/node/sales-invoice/node_modules/@opuscapita/i18n/lib/external_modules/date-and-time.js:215:17)
at Object.format (/home/node/sales-invoice/node_modules/@opuscapita/i18n/lib/external_modules/date-and-time.js:117:18)
at DateConverter.valueToString (/home/node/sales-invoice/node_modules/@opuscapita/i18n/lib/converters/DateConverter.js:72:36)
at I18nManager.formatDate (/home/node/sales-invoice/node_modules/@opuscapita/i18n/lib/utils/I18nManager.js:259:64)

Version 1.2.1 did support formatting on ISO strings.
As the result we currently use 1.2.1 of i18n manager because of the lost support.

Instead of getting stuck on version 1.2.1, could you include the lost ISO representation support again?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant