rdatediff

1.1.0 • Public • Published

DateDiff

Build Status

A simple and lightweight javascript date helper that calculates the difference between two dates.

Installation

Install via bower

bower install dateDiff --save

Sample usage

<script src="/dist/rDateDiff.min.js"></script>
var date1 = "02/13/2015";
var date2 = "12/23/2015";
 
var getDiff = rDate.getDiff(date1, date2);
var getDays = rDate.getDiffDays(date1, date2);
 
console.log(getDiff);
//Outputs => 10 months 13 days
 
console.log(getDays + 'days');
//Outputs => 313 days

License

MIT © Rexon A. De los Reyes

Thanks and enjoy. Godspeed!

Package Sidebar

Install

npm i rdatediff

Weekly Downloads

2

Version

1.1.0

License

MIT

Last publish

Collaborators

  • xrexonx