Reputation: 1
I am writing a system which shows customer data in front-end, but also allows exporting data via back-end to various file formats. I am using globalize.js and .NET's native Globalization capabilities, but for some languages I am getting differences in date format (eg. "31.1.2016" vs. "31-01-2016") and number format (eg. "1.234,56" vs "1 234,56"). Does anybody have any suggestion how can format dates and numbers across back-end and front-end and still get consistent results?
I can't pre-format values to string and pass strings to the front-end, because some front-end components (like charts) expect raw integers, dates to to be able to render the data properly.
Upvotes: 0
Views: 239
Reputation: 1717
You can pass from the back-end both things: The numerical date and the string representation.
Upvotes: 0