@hebcal/hdate
    Preparing search index...

    Function isGregLeapYear

    • Returns true if the Gregorian year is a leap year.

      Uses the proleptic Gregorian rule (divisible by 4, except centuries that are not divisible by 400) for all years, including those before the Gregorian calendar was adopted in 1582.

      Parameters

      • year: number

        Gregorian year

      Returns boolean

      true if February has 29 days in year

      isGregLeapYear(2000); // true
      isGregLeapYear(2020); // true
      isGregLeapYear(2023); // false
      isGregLeapYear(2100); // false (divisible by 100 but not 400)