Skip to content

getWeekOfYear

  • The core functions, which every industry uses.
getWeekOfYear(): number | null

Get the ISO week number of the current date.

  • Uses Temporal.Now.plainDateTimeISO() to get current date in system timezone.
  • Uses Temporal.PlainDate.weekOfYear for ISO week number.
  • Returns null when system timezone is unavailable.

The ISO week number (1-53), or null on invalid

import { getWeekOfYear } from "@northguild/gmt/plain/get";
getWeekOfYear() // 15
output 

plain/get/getWeekOfYear.ts

Accessibility
© 2026 NorthGuild · Licences

Code examples: MIT-0. Packages: MIT. Third-party data and components: their own licences, credited where they appear. Everything else: © 2026 NorthGuild, all rights reserved.