is-a-leap-year
v1.0.1
Published
Returns true if the year is a leap year.
Downloads
12
Maintainers
Readme
is-a-leap-year
Returns true
if the year is a leap year.
Install
Install with npm:
$ npm install --save is-a-leap-year
Usage
const isLeapYear = require('is-a-leap-year');
console.log(isLeapYear(2004)); // true
console.log(isLeapYear('2004')); // true
console.log(isLeapYear(new Date('2004-01-01'))); // true