Hi I'm trying to generate an array of every hour of the day. However, I want it to start with the current hour.
For example,
if the current time is 2:00 pm, the array should start:
['1400', '1500', '1600', 1700', '1800', '1900', '2000', '2100', '2200', '2300']
instead of
['0000', '0100', '0300', '0400', '0500', '0600', '0700', '0800', '0900', '1000', '1100', '1200', '1300', '1400', '1500', '1600', 1700', '1800', '1900', '2000', '2100', '2200', '2300']
.filter
withparseInt
and(new Date().getHours())
to filter all hours before the current hour of the day.