docusaurus
docusaurus copied to clipboard
feat: add <lastmod> to sitemap
Pre-flight checklist
- [x] I have read the Contributing Guidelines on pull requests.
- [x] If this is a code change: I have written unit tests and/or added dogfooding pages to fully verify the new behavior.
- [ ] If this is a new API or substantial change: the PR has an accompanying issue (closes #0000) and the maintainers have approved on my working plan.
Motivation
Add <lastmod>
to sitemap, should fix https://github.com/facebook/docusaurus/issues/2604.
Test Plan
Extend existing sitemap tests to expect generated lastmod date.
Test links
Deploy preview: https://deploy-preview-_____--docusaurus-2.netlify.app/sitemap.xml
Related issues/PRs
- https://github.com/facebook/docusaurus/issues/2604
Hi @pmarschik!
Thank you for your pull request and welcome to our community.
Action Required
In order to merge any pull request (code, docs, etc.), we require contributors to sign our Contributor License Agreement, and we don't seem to have one on file for you.
Process
In order for us to review and merge your suggested changes, please sign at https://code.facebook.com/cla. If you are contributing on behalf of someone else (eg your employer), the individual CLA may not be sufficient and your employer may need to sign the corporate CLA.
Once the CLA is signed, our tooling will perform checks and validations. Afterwards, the pull request will be tagged with CLA signed
. The tagging process may take up to 1 hour after signing. Please give it that time before contacting us about it.
If you have received this in error or have any questions, please contact us at [email protected]. Thanks!
[V2]
Built without sensitive environment variables
Name | Link |
---|---|
Latest commit | ddba059acc89798d39e85dab4b50e6cd9369a38c |
Latest deploy log | https://app.netlify.com/sites/docusaurus-2/deploys/65d602d27e9e3f0008b202bb |
Deploy Preview | https://deploy-preview-9234--docusaurus-2.netlify.app |
Preview on mobile | Toggle QR Code...Use your smartphone camera to open QR code link. |
To edit notification comments on pull requests, go to your Netlify site configuration.
⚡️ Lighthouse report for the deploy preview of this PR
URL | Performance | Accessibility | Best Practices | SEO | PWA | Report |
---|---|---|---|---|---|---|
/ | 🟠 59 | 🟢 98 | 🟢 100 | 🟢 100 | 🟠 89 | Report |
/docs/installation | 🟠 89 | 🟢 98 | 🟢 100 | 🟢 100 | 🟠 89 | Report |
/docs/category/getting-started | 🟠 77 | 🟢 100 | 🟢 100 | 🟢 90 | 🟠 89 | Report |
/blog | 🟠 75 | 🟢 100 | 🟢 100 | 🟢 90 | 🟠 89 | Report |
/blog/preparing-your-site-for-docusaurus-v3 | 🟠 64 | 🟢 97 | 🟢 100 | 🟢 100 | 🟠 89 | Report |
/blog/tags/release | 🟠 76 | 🟢 100 | 🟢 100 | 🟠 80 | 🟠 89 | Report |
/blog/tags | 🟠 77 | 🟢 100 | 🟢 100 | 🟢 90 | 🟠 89 | Report |
Thanks for submitting this @pmarschik ! Have you gotten any feedback on this PR? We use Docusaurus at Unleash and were just trying to add last mod to our docs since it is becoming increasingly important for Google. Would love to see this merged.
@ardeche07 I've not gotten any feedback, however I've been using the changes for our published docusaurus page for some time. When I get around it, I'll update the PR with the latest changes (its not actually 170 files changed, this PR was based on docusaurus v2)
Thanks for your contribution @pmarschik and sorry for the late review
Thank you for reviewing the MR @slorber.
Your PR is not really in a state I could merge, and try to implement things that are not really needed according to Google recommendations.
It should also target
main
and notdocusaurus-v3
branch
I'm aware, this is just what I use to pnpm patch
our build and have a working lastmod until the feature is available upstream.
Let me know if you want to give it another try, otherwise I'll create another PR.
I'm currently occupied with other projects and I don't know when I next have time to circle back to this. So I think it would be best if you create another PR.
Thanks
I'll close this one in favor of a new one, track https://github.com/facebook/docusaurus/pull/9954