-
-
Notifications
You must be signed in to change notification settings - Fork 8.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(sitemap): allow customizing the output name #7469
Conversation
✅ [V2]
To edit notification comments on pull requests, go to your Netlify site settings. |
⚡️ Lighthouse report for the deploy preview of this PR
|
Size Change: -95 B (0%) Total Size: 796 kB
ℹ️ View Unchanged
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🤷♂️ ok to add this, but I'm not sure to understand the use-case in practice
The docs state that "all Docusaurus content plugins can support multiple plugin instances". This support should extent to other plugins such as plugin-sitemap. For example, we want to weight docs differently in SEO based on their doc ID.
Yes but... all the sitemap plugins would receive the same routes, so unless you plan with the ignorePatterns
you end up with the same result 🤷♂️
Now, about "weighting" some docIds, I don't know what the op means exactly
https://developers.google.com/search/docs/advanced/sitemaps/build-sitemap#general-guidelines
Google ignores and values.
Thanks for this. I actually have a use case. I have a section of my site behind http-auth, and would like to exclude those pages from my sitemap that gets submitted to google for indexing. Google continually warns me it can't reach all those pages in the sitemap. But I also need a full sitemap to pass to the algolia self hosted crawler to still index those pages (that crawls with http-auth). I intended to publish two sitemaps, one for algolia indexing, one for google, this will make that easier. |
Thanks for clarifying, I wouldn't have been able to think of this use-case 🤪 |
Pre-flight checklist
Motivation
See https://docusaurus.canny.io/feature-requests/p/support-multi-instance-sitemaps-plugins
Since sitemap files can be manually uploaded/checked-in, the name is mostly irrelevant.
Test Plan
We don't have tests for this...
Test links
Deploy preview: https://deploy-preview-7469--docusaurus-2.netlify.app/docs/api/plugins/@docusaurus/plugin-sitemap/
Related issues/PRs