3 ms·
You misunderstood, that's my point. If you send it in ISO8601 as a UTC date, it's always wrong in that scenario. If you leave off the Z, browsers all do differe
by mattmanser 9y ago
You misunderstood, that's my point. If you send it in ISO8601 as a UTC date, it's always wrong in that scenario. If you leave off the Z, browsers all do different weird things (and worse, Chrome recently changed how the interpret ISO8601 dates without a Z).
But if you send it in yyyy/MM/dd hh:mm:ss format, a format supported by all JS clients, it's unambiguously a relative date and won't be interpreted incorrectly by the browser.
Annoyingly, moment.js seem to be threatening to drop support for that format.
- iDemonix 9y agoWhy overcomplicate when a UTC timestamp works perfectly and takes up less space?