11 lines
225 B
TypeScript
11 lines
225 B
TypeScript
const formatDate = (dateString: string) => {
|
|
return new Date(`${dateString}`).toLocaleDateString('pt-PT', {
|
|
day: 'numeric',
|
|
month: 'long',
|
|
year: 'numeric',
|
|
timeZone: 'UTC',
|
|
})
|
|
}
|
|
|
|
export default formatDate
|