Link hompeage eventlist to backend

This commit is contained in:
T'JAMPENS QUENTIN p2406187
2026-01-07 14:55:17 +01:00
parent 1936151267
commit 7f5be9ea32
3 changed files with 56 additions and 24 deletions
+7 -3
View File
@@ -3,6 +3,10 @@ export default function formatDateLetter(d) {
"Janvier", "Février", "Mars", "Avril", "Mai", "Juin",
"Juillet", "Août", "Septembre", "Octobre", "Novembre", "Décembre"
];
const [year, month, day] = d.split('-');
return `${day} ${monthNames[parseInt(month) - 1]} ${year}`;
};
const [datePart, timePart] = d.split(' ');
const [year, month, day] = datePart.split('-');
const [hours, minutes] = timePart.split(':');
return `${day} ${monthNames[parseInt(month, 10) - 1]} ${year} à ${hours}:${minutes}`;
}