Showing posts with label compare. Show all posts
Showing posts with label compare. Show all posts

Monday, 24 February 2020

JavaScript date : How to compare two dates to check which one is greater?


Example:

if(startDate.getTime() == endDate.getTime()) //both the dates are same
{
            //do something
}