Skip to content

micnews/date-parse

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SYNOPSIS

Parse date value into valid Date() object or null. Never returns date object that is invalid and could throw like so:

new Date('not a date').toISOString() // throws RangeError: Invalid time value

Build Status

USAGE

var dateParse = require('date-parse');
dateParse('2014-12-30T21:17:46.826Z') // new Date('2014-12-30T21:17:46.826Z')
dateParse('not a date') // null

##LICENSE

MIT

About

Parse date value into valid Date() object or null

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •