I have an array of date object:
const dates = [
'2021-11-01T19:49:08.678Z',
'2021-11-01T20:13:27.954Z',
'2021-08-31T19:15:16.452Z',
'1983-04-16T20:18:39.802Z',
'2022-02-02T20:26:14.992Z',
'2022-02-02T20:30:36.374Z',
'2022-02-02T20:33:09.266Z',
'2022-02-02T20:35:34.615Z',
'2022-02-02T20:44:19.131Z',
'2022-02-02T20:48:17.274Z'
]
I want to check if at least one of the dates inside the array is later than the current date (if there is any date which has not reached yet return true
, if all of them past return false
)