Note this works universally, because toDateString() produces date string with your browser's localization (without the time component), and the new Date()uses the same localization to parse that date string.
You can extend the Date object as below, so and then use the dateOnly property:
Date.prototype.getDateWithoutTime = function () {
return new Date(this.toDateString());
}
Now <any-date-object>.getDateWithoutTime(); will output Date only