javascript - Update a property on list of object array and then retrieve the updated list -
i have list of object array shown below.i need apply moment.tz("2013-11-18 11:55", "america/toronto");
lastupdate
properties , retrieve updated new array.so how can ?.i can use underscore.js.thanks in advance.
any reason simple loop won't work?
for(var = 0; < progress.length; i++) { progress[i].lastupdate = moment.tz(progress[i].lastupdate, 'america/toronto'); }
or
progress.foreach(function (x) { x.lastupdate= moment.tz(x.lastupdate, 'america/toronto'); });
Comments
Post a Comment