First of all I don't get the minus votes. This is a good question. However asked already. There is Intl.DateTimeFormat available: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Intl/DateTimeFormat
Explained here as well: How to format a JavaScript date
You can also use toISOString(), toLocaleDateString, toDateString etc.
new Date(1590486552434).toISOString();
"2020-05-26T09:49:12.434Z"
new Date(1590486552434).toLocaleDateString();
"5/26/2020"
and the link example
const d = new Date('2010-08-05')
const ye = new Intl.DateTimeFormat('en', { year: 'numeric' }).format(d)
const mo = new Intl.DateTimeFormat('en', { month: 'short' }).format(d)
const da = new Intl.DateTimeFormat('en', { day: '2-digit' }).format(d)
console.log(`${da}-${mo}-${ye}`)