Reputation: 24395
In the Moment Timezone documentation, it states that a date/time can be created via a timezone name, like so:
moment().tz("America/Los_Angeles").format();
But how can I create a date/time with a timezone code?
I have tried this, but had no luck:
moment().tz("GMT+8:00").format();
Upvotes: 0
Views: 1369
Reputation: 7958
You would use "Etc/GMT+8". You can use the data builder to build the data: http://momentjs.com/timezone/data/
moment().tz("Etc/GMT+8").format();
Upvotes: 1