javascript - MomentJS India's 5 + half-hour -


i wondering how can pre-define india's timezone while it's containing half-hour +5:30 ?

i trying add 1 myself since couldn't find example doesn't contain round hour under: http://momentjs.com/timezone/data/ couldn't find one, instead i'm doing this:

moment.tz.add({             "zones": {                 "ist": [                     "+5 - ist"                 ], .... });  var = "2014-03-10 10:00";     = moment(now).tz("ist"); // adjusting localized "now" ist  if ( tz == "ist" )  now.add("minutes", 30); 

but still want predefine "+5" half-hour , remove "if" - how can ?

this works me(copied straight docs):

moment.tz.add({     "zones": {         "asia/kolkata": [             "5:53:28 - lmt 1880 5:53:28",             "5:53:20 - hmt 1941_9 5:53:20",             "6:30 - burt 1942_4_15 6:30",             "5:30 - ist 1942_8 5:30",             "6:30 - ist 1945_9_15 6:30",             "5:30 - ist"         ]     },     "rules": {},     "links": {} }); 

Comments

Popular posts from this blog

Android layout hidden on keyboard show -

google app engine - 403 Forbidden POST - Flask WTForms -

c - Why would PK11_GenerateRandom() return an error -8023? -