Skip to content

isAfterTime

isAfterTime(value1: string, value2: string): boolean

Return true when value1 is strictly after value2 for PlainTime values.

  • Uses Temporal.PlainTime.compare to compare times.
  • Returns false if either input is invalid.
ParameterTypeDescription
value1stringISO PlainTime string for the first value
value2stringISO PlainTime string for the second value

boolean indicating whether value1 > value2

import { isAfterTime } from "@northguild/gmt/plain/compare";
isAfterTime("12:34:56", "11:34:56") // true
output 

plain/compare/isAfterTime.ts