The most clear way to format a date (dd/mm/yyyy) or (yyyy/mm/dd) in React is to use: date-fns. Also, in this article you will learn how to format dates with just Vanilla JavaScript!
Basically, using setTimeout in React, you should be able to create a function inside the useEffect hook, or in the case of classes components, inside componenDidMount.