Skip to content

Releases: softwareventures/timestamp

v2.2.2

18 May 09:39
8ab9427

Choose a tag to compare

2.2.2 (2024-05-18)

Bug Fixes

  • delete pinst from prepack and postpack scripts (8ab9427)

v2.2.1

18 May 09:22
181ef5e

Choose a tag to compare

2.2.1 (2024-05-18)

Bug Fixes

  • compatibility with npm >= 10.4 (181ef5e)

v2.2.0

16 Apr 11:47
0c7807d

Choose a tag to compare

2.2.0 (2024-04-16)

Features

  • deps: add support for @softwareventures/date v5 (7ff2055)
  • fromJsDate: add timestampFromJsDate alias (384be21)

v1.4.0

16 Apr 11:46
384be21

Choose a tag to compare

1.4.0 (2024-04-16)

Features

  • fromJsDate: add timestampFromJsDate alias (384be21)

v2.1.0

16 Feb 09:02
4a5c80a

Choose a tag to compare

2.1.0 (2024-02-16)

Features

  • deps: add support for @softwareventures/date v5 (95b8675)

v2.0.0

16 Feb 05:05
449a802

Choose a tag to compare

2.0.0 (2024-02-16)

⚠ BREAKING CHANGES

  • TimestampOptions: When constructing a Timestamp from
    TimestampOptions, all fields are now mandatory
    except for type, minutes, and seconds.
  • latest: The latest and
    latestTimestamp functions now take exactly two
    Timestamps as arguments instead of an Iterable. The
    advantage of this approach is that the function never
    returns null. If you need the old behaviour,
    compose it by using the fold function from
    @softwareventures/iterable instead.
  • earliest: The earliest and
    earliestTimestamp functions now take exactly two
    Timestamps as arguments instead of an Iterable. The
    advantage of this approach is that the function never
    returns null. If you need the old behaviour,
    compose it by using the fold function from
    @softwareventures/iterable instead.
  • fromReferenceSeconds: The functions timestamp,
    normalize, normalizeTimestamp,
    fromReferenceSeconds,
    timestampFromReferenceSeconds, earliest,
    earliestTimestamp, earliestFn,
    earliestTimestampFn, latest, latestTimestamp,
    latestFn, and latestTimestampFn now throw
    Error if any numeric values are non-finite.
  • The discriminator string has
    changed from "timestamp" (lowercase) to "Timestamp"
    (capital "T"). This change will break for consumers
    who check the discriminator directly (for example to
    discriminate from other types in a union) or who
    serialize and deserialize Timestamp objects with the
    discriminator intact.
  • node: node versions < 18, 19 are no longer
    supported.

Features

  • change discriminator string from "timestamp" to "Timestamp" (e126a03)
  • earliest: take exactly two Timestamps as arguments instead of an Iterable (eb34f8b)
  • latest: take exactly two Timestamps as arguments instead of an Iterable (e6eb29c)
  • node: drop support for node < 18, 19 (ad84de6)
  • TimestampOptions: require all fields except type, minutes, seconds (7f55f7c)

Bug Fixes

  • fromReferenceSeconds: throw Error if referenceSeconds is non-finite (cc97458)
  • TimestampOptions: fix seconds being incorrectly required (f7dfa2f)

v1.3.0

16 Feb 09:02
7ff2055

Choose a tag to compare

1.3.0 (2024-02-16)

Features

  • deps: add support for @softwareventures/date v5 (7ff2055)

v1.2.0

16 Feb 04:59
376c973

Choose a tag to compare

1.2.0 (2024-02-16)

Features

  • add constants for each month (156fcd9)
  • after: add timestampAfter and timestampAfterFn aliases (63036ce)
  • afterOrEqual: add timestampAfterOrEqual and timestampAfterOrEqualFn aliases (7897d4d)
  • before: add timestampBefore and timestampBeforeFn aliases (5825f24)
  • beforeOrEqual: add timestampBeforeOrEqual and timestampBeforeOrEqualFn aliases (bfadee1)
  • compare: add compareTimestamps and compareTimestampsFn aliases (6db2a2f)
  • earliest: add earliestTimestamp and earliestTimestampFn aliases (beda1a0)
  • equal: add timestampsEqual and timestampsEqualFn aliases (7df6fe6)
  • formatIso8601: add formatTimestampIso8601 alias (881ec93)
  • fromReferenceSeconds: add timestampFromReferenceSeconds alias (a331b63)
  • isValid: add isTimestampValid alias (ef2a702)
  • isValid: add isValid function (86f7d61)
  • isValidTimestamp: add isValidTimestamp function (b44096b)
  • latest: add latestTimestamp and latestTimestampFn aliases (bb879fc)
  • notEqual: add timestampsNotEqual and timestampsNotEqualFn aliases (b44819c)
  • now: add timestampNow alias (2c0fce7)
  • parseIso8601: accept any sequence of whitespace characters in place of the "T" delimiter (23dd7c9)
  • parseIso8601: add parseTimestampIso8601 alias (e0d7d1e)
  • timestamp: add normalizeTimestamp alias (04e5b48)
  • toReferenceSeconds: add timestampToReferenceSeconds alias (42c6f22)
  • validate: add validate function (4d8e776)

v1.1.2

15 Feb 13:26
8af66db

Choose a tag to compare

1.1.2 (2024-02-15)

v1.1.1

26 Jan 19:41
10bf5f9

Choose a tag to compare

1.1.1 (2024-01-26)

Bug Fixes

  • parseIso8601: accept lower-case "t" delimiter in place of "T" per ISO 8601 and RFC3339 (10bf5f9)