Skip to content

Question - Localized Date Format by Timezone #453

@lwelti

Description

@lwelti

Maybe I am missing it, but I don't see a way to get the Localized DateTime Format based on the Time Zone.
Having:
var testDate = new Date(Date.UTC( 2014, 2, 21, 0, 0, 0 ));
formatDate( testDate, { datetime: "medium" });

and for 2 different Time Zones get a different Output:

A) for Time Zone: America/Los_Angeles get:
Mar 20, 2014, 5:00:00 PM

B) for America/Mexico_City get:
Mar 20, 2014, 7:00:00 PM

I didn't see a way to pass the TZ, but maybe I am missing it.
thanks

@rxaviers

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions