Skip to content

datetime/leap-year

Repository files navigation

leap-year Build Status

Check if a year is a leap year

Install

$ npm install --save leap-year

Usage

var leapYear = require('leap-year');

leapYear(2014);
//=> false

leapYear(2016);
//=> true

API

leapYear([year])

year

Type: number
Default: current year

leapYear([date])

date

Type: date
Default: new Date()

License

MIT © Sindre Sorhus

About

Check if a year is a leap year

Resources

License

Stars

Watchers

Forks

Packages

No packages published