From 39da8ee18415c4e84b586477cc6a823372c0562f Mon Sep 17 00:00:00 2001 From: Greg Date: Sat, 10 May 2025 17:33:38 +0200 Subject: [PATCH] Current date at line 2 --- static/app.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/static/app.js b/static/app.js index 1763c19..add7b02 100644 --- a/static/app.js +++ b/static/app.js @@ -44,7 +44,8 @@ function renderTable() { // Body rows const tbody = document.createElement('tbody'); if (!data.guestNames) data.guestNames = {}; - data.dates.forEach((date, rowIdx) => { + // Show most recent date at the top + [...data.dates].slice().reverse().forEach((date, rowIdx) => { const tr = document.createElement('tr'); // Date cell const dateTd = document.createElement('td');