Skip to content

chore: sitemap paths added into the robots.txt#8820

Open
canerakdas wants to merge 1 commit intonodejs:mainfrom
canerakdas:chore/sitemap
Open

chore: sitemap paths added into the robots.txt#8820
canerakdas wants to merge 1 commit intonodejs:mainfrom
canerakdas:chore/sitemap

Conversation

@canerakdas
Copy link
Copy Markdown
Member

Description

Since we now have multiple sitemap files, the sitemap paths have been added to robots.txt for the SEO.

Validation

In preview environment the robots.txt should contains

Sitemap: https://nodejs.org/sitemap.xml
Sitemap: https://nodejs.org/learn/sitemap.xml

Related Issues

Related with this comment; nodejs/learn#47 (review)

Check List

  • I have read the Contributing Guidelines and made commit messages that follow the guideline.
  • I have run pnpm format to ensure the code follows the style guide.
  • I have run pnpm test to check if all tests are passing.
  • I have run pnpm build to check if the website builds without errors.
  • I've covered new added functionality with unit tests if necessary.

@canerakdas canerakdas requested a review from a team as a code owner April 14, 2026 14:51
Copilot AI review requested due to automatic review settings April 14, 2026 14:51
@cursor
Copy link
Copy Markdown

cursor bot commented Apr 14, 2026

PR Summary

Low Risk
Low risk: adds static sitemap declarations to robots.txt without changing crawling rules or any runtime logic.

Overview
Updates the generated robots.txt metadata to include multiple sitemap entries, adding both ${BASE_URL}/sitemap.xml and ${BASE_URL}/learn/sitemap.xml so search engines can discover all sitemap files.

Reviewed by Cursor Bugbot for commit 1f801d9. Bugbot is set up for automated code reviews on this repo. Configure here.

@github-actions
Copy link
Copy Markdown
Contributor

👋 Codeowner Review Request

The following codeowners have been identified for the changed files:

Team reviewers: @nodejs/nodejs-website

Please review the changes when you have a chance. Thank you! 🙏

@vercel
Copy link
Copy Markdown

vercel bot commented Apr 14, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
nodejs-org Ready Ready Preview Apr 14, 2026 2:53pm

Request Review

@codecov
Copy link
Copy Markdown

codecov bot commented Apr 14, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 74.25%. Comparing base (69cc705) to head (1f801d9).
⚠️ Report is 2 commits behind head on main.
✅ All tests successful. No failed tests found.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #8820      +/-   ##
==========================================
- Coverage   74.27%   74.25%   -0.03%     
==========================================
  Files         104      104              
  Lines        8847     8847              
  Branches      328      328              
==========================================
- Hits         6571     6569       -2     
- Misses       2274     2276       +2     
  Partials        2        2              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds sitemap references to the dynamically generated robots.txt so crawlers can discover multiple sitemap files.

Changes:

  • Import BASE_URL for constructing absolute sitemap URLs.
  • Add two sitemap entries (/sitemap.xml and /learn/sitemap.xml) to the MetadataRoute.Robots output.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants