MCPcopy Create free account
hub / github.com/Effect-TS/effect / isLeapYear

Function isLeapYear

packages/sql/pg/src/PgTypes.ts:545–545  ·  view source on GitHub ↗
(year: number)

Source from the content-addressed store, hash-verified

543const monthLengths = [0, 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31]
544
545const isLeapYear = (year: number): boolean => (year % 4 === 0 && year % 100 !== 0) || year % 400 === 0
546
547/** The two-digit number at `at`, or `-1` when those characters are not digits. */
548const twoDigitsAt = (text: string, at: number): number => {

Callers 1

parseDateFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected