sitemap update

This commit is contained in:
2025-11-20 11:58:23 +01:00
parent 4d20434319
commit 4a14dd20a4
6 changed files with 429 additions and 453 deletions

View File

@@ -8,9 +8,9 @@
function reloadStylesheets() {
// Force reload all stylesheets
const links = document.querySelectorAll('link[rel="stylesheet"]');
links.forEach(link => {
const href = link.href.split('?')[0];
link.href = href + '?t=' + new Date().getTime();
links.forEach((link) => {
const href = link.href.split("?")[0];
link.href = href + "?t=" + new Date().getTime();
});
}
@@ -32,10 +32,10 @@
const data = JSON.parse(event.data);
if (data.type === "reload") {
console.log("Repository updated, reloading page...");
// First reload stylesheets
reloadStylesheets();
// Then hard reload the page after a brief delay
setTimeout(() => {
window.location.reload(true);
@@ -69,4 +69,4 @@
eventSource.close();
}
});
})();
})();