Skip to content

Riim/date-exists

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

date-exists

Check if a date exists.

Install

npm install date-exists --save

Usage

import dateExists from 'date-exists';
// or `var dateExists = require('date-exists').default;`

dateExists('01/01/1970');
// => true

dateExists('1/1/80'); // 01/01/1980
// => true

dateExists('0/1/1900');
// => false

dateExists('29/02/1900'); // 1900 - not a leap year
// => false

dateExists('29/02/1904'); // 1904 - leap year
// => true

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published