I am attempting to retrieve the current date and time, with the specified time using moment js. Here's what I have tried.
const time = '18:00'
const timeAndDate = moment(time)
However, when I display timeAndDate
, it indicates an invalid date. Is there a different method to accomplish this?