Files
bflows-bandi-fe/src/helpers/getDateFromISOstring.js
2024-09-30 11:00:34 +02:00

9 lines
272 B
JavaScript

const getDateFromISOstring = (
value,
options = {
day: '2-digit', month: '2-digit', year: 'numeric', hour12: false
}) => {
return value ? Intl.DateTimeFormat('it-IT', options).format(new Date(value)) : value;
}
export default getDateFromISOstring;