I am trying to format my date in React/ typescript project, however the data is from an api, so I can map over the data and display it but how do I convert it to a format like '22 June 2021'?
The data from the api is in format:
[
{
"title": 'First',
"date": "2020-07-22T13:22:10.2566789+00:00",
}
]
in template binding as:
const Component = () => {
{data.map(inner => {
return (
<p>{inner.title}</p>
<p>{inner.date}</p>
)
})}
}
question is where and how do I convert the date, so I can bind it into the template?