I'm using Intl
library in my javascript code, as below:
const dateFormat = new Intl.DateTimeFormat(locale, {
day: '2-digit',
month: '2-digit',
year: 'numeric',
});
kk = new Date('1992-10-28')
dateFormat.format(kk, 'en-Us') ==> "10/28/1992"
But I want something like "dd/mm/yyyy"
as response:
let format = dateFormat.getFormat('en-Us'); // --> "dd/mm/yyyy"