I'm building a weather app and I'm fetching weather and other information from openweathermap.org. I would like to get sunrise and sunset information for each of the searched location but I'm not sure how to change the format from seconds into hh:mm
My code is:
document.querySelector("#sunrise").innerHTML = ${ DateTime.fromMillisecondsSinceEpoch(response.data.sys.sunrise) * 1000 }
;
I tried searching online and came with the above but it doesn't work.