Created
February 25, 2019 12:16
-
-
Save servatj/0e13d8ca59d7523219b181029a69287e to your computer and use it in GitHub Desktop.
Revisions
-
servatj created this gist
Feb 25, 2019 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,5 @@ var oneDay = 24*60*60*1000; // hours*minutes*seconds*milliseconds var firstDate = new Date(2018,08,13); var secondDate = new Date(2019,02,25); var diffDays = Math.round(Math.abs((firstDate.getTime() - secondDate.getTime())/(oneDay)));