I tried this method to check duplicate date in the array with date string array, but didn't work Please anyone can help..
const dateArray = ["2000-07-13","03/24/2000", "June 7 2021"]
const compaingDate =new Date("2000-06-13")
let countOfDays=0
for(let sameDate of dateArray){
if(compaingDate.getDate()===sameDate.getDate()){
countOfDays+=1
}
}
console.log(countOfDays);