fix: sitemap URLs not XML-encoded and no sitemap index for large sites
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 2
- Forks
- 1
- Avg merge
- 12h 29m
- Merged PRs (30d)
- 12
Description
Problem
`src/server/routes/sitemap.xml.ts` has two issues:
-
URLs not encoded — slugs with special characters (`&`, `<`, spaces) break XML validity:
```xml
https://docs.example.com/guides/Q&A
``` -
No sitemap index — generates a single monolithic sitemap. Google's limit is 50MB / 50,000 URLs. Large doc sites with many API endpoints could exceed this.
Suggested Fix
- XML-encode all URL values in the sitemap
- For sites exceeding 10k URLs, generate a sitemap index pointing to paginated sitemaps
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with src/server/routes/sitemap.xml.ts and inspect how URL values and the current single sitemap are generated. Verify that special characters produce valid XML, then define and check the sitemap index and paginated output for sites exceeding 10,000 URLs.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- backend, web-dev
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 62/100