SyntaxFix
Write A Post
Hire A Developer
Questions
Comparing with setHours() will be a solution. Sample:
setHours()
var d1 = new Date(); var d2 = new Date("2019-2-23"); if(d1.setHours(0,0,0,0) == d2.setHours(0,0,0,0)){ console.log(true) }else{ console.log(false) }