'Changing JSON date format received from API. ReactJS

would appreciate any help on this. I am using this API and the data is returned in JSON format. However, the date/time is returned as a value similar to this: dt: 1645068034 How can I convert this to a readable format in my react project?



Solution 1:[1]

Here's an option for you:

new Date(1645068034 * 1000)

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Rolando Yera