π Patch Changes
- #10779
cefeadfThanks @adrianlyjak! - Fixes false positives for status code routes like404and500when generating sitemaps.
cefeadf Thanks @adrianlyjak! - Fixes false positives for status code routes like 404 and 500 when generating sitemaps.0e22462d1534afc8f7bb6782f86db680c7a5f245 Thanks @gislerro! - Fixes an issue where the root url does not follow the trailingSlash config option1ce22881c657becf0397b83ac393fb5d2399104c Thanks @bluwy! - Improves performance when generating the sitemap data5f7e9c47e01116f6ec74b33770f480404680956a Thanks @mingjunlu! - Fixes an issue where the base path is missing in sitemap-index.xml.#10179 6343f6a438d790fa16a0dd268f4a51def4fa0f33 Thanks @ematipico! - Revert https://github.com/withastro/astro/pull/9846
The feature to customize the file name of the sitemap was reverted due to some internal issues with one of the dependencies. With an non-deterministic behaviour, the sitemap file was sometime emitted with incorrect syntax.
#9975 ec7d2ebbd96b8c2dfdadaf076bbf7953007536ed Thanks @moose96! - Fixes URL generation for routes that rest parameters and start with /
#9846 9b78c992750cdb99c40a89a00ea2a0d1c00877d7 Thanks @ktym4a! - Adds a new configuration option prefix that allows you to change the default sitemap-*.xml file name.
By default, running astro build creates both sitemap-index.xml and sitemap-0.xml in your output directory.
To change the names of these files (e.g. to astrosite-index.xml and astrosite-0.xml), set the prefix option in your sitemap integration configuration:
import { defineConfig } from 'astro/config';import sitemap from '@astrojs/sitemap';export default defineConfig({ site: 'https://example.com', integrations: [ sitemap({ prefix: 'astrosite-', }), ],});This option is useful when Google Search Console is unable to fetch your default sitemap files, but can read renamed files.
b325fada567892b63ecae87c1ff845c8514457ba Thanks @andremralves! - Fixes generated URLs when using a base with a SSR adapter1baf0b0d3cbd0564954c2366a7278794fad6726e Thanks @sarah11918! - Updates README35cd810f0 Thanks @evadecker! - Upgrades Zod to 3.22.410b103820 Thanks @silent1mezzo! - Display output directory in the sitemap build result1eae2e3f7 Thanks @Princesseuh! - Remove support for Node 16. The lowest supported version by Astro and all integrations is now v18.14.1. As a reminder, Node 16 will be deprecated on the 11th September 2023.77ffcc8f8 Thanks @natemoo-re! - Ensure nested 404 and 500 pages are always excludeddd931a780 Thanks @natemoo-re! - Sitemap only includes page routes (generated by .astro files) rather than all routes (pages, endpoints, or redirects). This behavior matches our existing documentation, but is a breaking change nonetheless.dd931a780 Thanks @natemoo-re! - Ensure trailing slash is only added to page routesc258492b7 Thanks @natemoo-re! - Ensure sitemap only excludes numerical pages matching /404 and /500 exactlydff0d0dda Thanks @andremralves! - Fix sitemap does not filter pages6ca3b5a9e Thanks @alexanderniebuhr! - exported enum type to support typescript > 5.01b90a7a5d Thanks @TheOtterlord! - Fix generation for static dynamic routes