. Advertisement .
..3..
. Advertisement .
..4..
How to convert datetime to date in Javascript? I am learning about it. Can someone share with me your knowledge and experience?
let dateStr =new Date("Wed Aug 04 18:11:48 UTC 2022")
dateStr.toLocaleDateString() // "04/08/2022"
dateStr.toTimeString() // "23:41:48 GMT+0530 (India Standard Time)"
Hope that my example would help
One of the basic solutions