From 9f0bf7c32b137354e17ac29ea17da6b4f3caab47 Mon Sep 17 00:00:00 2001 From: wearrrrr Date: Fri, 20 Sep 2024 11:44:54 -0500 Subject: [PATCH] Fix the sitemap up a little bit. --- astro.config.mjs | 1 + src/pages/game/[game].astro | 10 ++++++---- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/astro.config.mjs b/astro.config.mjs index 7242f88..e377fe7 100644 --- a/astro.config.mjs +++ b/astro.config.mjs @@ -13,6 +13,7 @@ export default defineConfig({ integrations: [ sitemap({ includeByDefault: true, + lastmod: new Date(), }), ], output: "server", diff --git a/src/pages/game/[game].astro b/src/pages/game/[game].astro index c28edbb..c4e04d4 100644 --- a/src/pages/game/[game].astro +++ b/src/pages/game/[game].astro @@ -7,16 +7,18 @@ import sitemap from 'sitemap-ext:config'; const gamesList = games as GameList; -sitemap(async ({ setSitemap }) => { + +sitemap(async ({ setSitemap}) => { const gamesList = games as GameList; const urls = Object.keys(gamesList); setSitemap( urls.map((game) => ({ sitemap: true, params: { - game, - } - })) + game: game, + }, + }), + ) ); });