Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback
Module

std/datetime/is_leap.ts

The Deno Standard Library
Go to Latest
import * as mod from "https://deno.land/std@0.222.1/datetime/is_leap.ts";

Functions

Returns whether the given year is a leap year. Passing in a Date object will return the leap year status of the year of that object and take the current timezone into account. Passing in a number will return the leap year status of that number.

Returns whether the given year is a leap year in UTC time. This always returns the same value regardless of the local timezone.