Skip to content

getSecond

getSecond(): string
import { getSecond } from "@northguild/gmt/plain/get";

Return the current second using the system timeZone.

  • Uses Temporal.Now.plainDateTimeISO to get current second in system timezone.
  • Returns zero-padded string (e.g., “45”).
  • Returns “” when system timezone is unavailable.

current second string (zero-padded) or “” on invalid

getSecond() // "00"
getSecond() // "" (when system timeZone unavailable)

plain/get/getSecond.ts