Created
July 26, 2022 21:12
-
-
Save 3200pro/cde15e38eeb93498d56c90ef0e165776 to your computer and use it in GitHub Desktop.
Get the daily difference between two dates
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 characters
const daysBetween = (date1, date2) => Math.ceil(Math.abs(date1 - date2) / (1000 * 60 * 60 * 24)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment