Hello!
When we register the sitemap endpoints, we are yet unaware if any (exotic) translation plugin is active, nor how they’re configured. The translation plugin changes the language based on the endpoint parameters, such as ?lang=es
, at which point we can read the language registered and generate a different sitemap if needed.
As for the Yoast SEO endpoint, we added it not because of Yoast SEO’s plugin but because of their erroneous documentation. This documentation causes some bad hosts to only support Yoast SEO’s sitemap endpoint (by, for example, redirecting /sitemap.xml
to /sitemap_index.xml
). This can make our /sitemap.xml
endpoint unavailable — hence, we also support the /sitemap_index.xml
endpoint to display a sitemap. When we register the sitemap endpoints, we cannot tell how the site/host responds to them — so we register them all.
The registration of these endpoints does not affect the rest of the site, so removing them is unnecessary. Allowing users to toggle these alternative endpoints doesn’t help the user in any beneficial way (not even for performance); it’ll only confuse them. Hence, we do not provide an option.