A lightweight javascript timezone library
OTHER License
Published by spencermountain almost 4 years ago
Published by spencermountain almost 4 years ago
Published by spencermountain about 4 years ago
America/Fort_Nelson
, Asia/Qostanay
, and America/Nuuk
.isSame()
and .since()
accross different timezonesPublished by spencermountain about 4 years ago
Published by spencermountain about 4 years ago
Published by spencermountain about 4 years ago
.date()
methodPublished by spencermountain over 5 years ago
.every(unit, to)
method.hour(24)
now changes date to tomorrow.i18n()
inputsPublished by spencermountain almost 6 years ago
.format()
nov 2019
tues March 5th 2018
inputsnext()
and last()
methodsPublished by spencermountain almost 6 years ago
s = s.add(1,'day')
s.add(1,'day')
).format()
into .unixFmt()
{hour} oclock
-style format templates.format()
response to yyyy-mm-dd
.dayName()
EST
, PDT
, etc as inputsilent: true
to avoid unwanted logging.format()
format(iso)
now uses .
for millisecond separator: 2016-11-04T09:00:59.122Z
.since()
method to calculate a human-readable diff.diff()
June 5th 2018
.diff()
without a unit does a couple units together.from()
and .fromNow()
methods.valid
boolean on Spacetime class.extend()
method for authoring pluginsspacetime('July 5th')
.diff()
operations (gt 1yr) in fast-modes.format('year')
-0500 → +5 offset
#61
Published by spencermountain over 6 years ago
dramatic speedup
before 20k dates: 3.3s
after 20k dates: 0.8s
Published by spencermountain over 6 years ago
Intl
is present