Skip to content

Conversation

@TechWithTy
Copy link
Owner

No description provided.

Codex CLI added 2 commits November 29, 2025 10:21
- Add Beehiiv blog posts to sitemap with correct dealscale.io URLs
- Remove external URLs (YouTube, GitHub) that aren't allowed in sitemaps
- Add comprehensive validation to filter empty/invalid URLs
- Ensure all entries have required fields (lastModified, changeFrequency, priority)
- Add local sitemap validation script (pnpm run validate:sitemap)
- Fix property name consistency (changefreq -> changeFrequency)

BREAKING CHANGE: External URLs removed from sitemap per Google Search Console requirements
@vercel
Copy link

vercel bot commented Nov 29, 2025

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

Project Deployment Preview Comments Updated (UTC)
deal-scale Ready Ready Preview Comment Nov 29, 2025 10:07pm

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines 99 to +114
const blogPosts = await Promise.all(
posts.map(async (post) => {
// Construct dealscale.io URL format: /blogs/{post_id}
// Don't use post.web_url as it's likely a Beehiiv URL
const url = `${baseUrl}/blogs/${post.id}`;

Choose a reason for hiding this comment

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

P1 Badge Sitemap now links blog posts to non-existent routes

The sitemap now forces every blog entry to ${baseUrl}/blogs/${post.id} and deliberately avoids the post.web_url Beehiiv link. The app only defines the /blogs index (no [id] or rewrite routes under src/app/blogs), so these generated URLs resolve to 404s while previously they pointed to the live Beehiiv pages. This leaves the sitemap advertising broken links to search engines whenever it is generated.

Useful? React with 👍 / 👎.

Codex CLI added 3 commits November 29, 2025 14:47
- Add /blogs/[id] route handler that redirects to Beehiiv URLs (301)
  - Fixes broken links in sitemap reported by code review
  - Allows sitemap to use dealscale.io URLs while redirecting to actual content
  - Handles missing posts gracefully with 404 or redirect to /blogs

- Fix TypeScript errors in sitemap.ts
  - Add 'as const' assertions to changeFrequency values
  - Ensure proper literal type inference for MetadataRoute.Sitemap
  - Add explicit type validation for changeFrequency in final mapping

- Add comprehensive sitemap validation tests (25 tests, all passing)
  - URL validation (canonical domain, format, duplicates)
  - Required fields validation (lastModified, changeFrequency, priority)
  - Content coverage (homepage, static pages, RSS feeds, blog posts, etc.)
  - Exclusions validation (no /careers, no external URLs)
  - Priority and change frequency distribution
  - Edge cases handling

This ensures the sitemap is Google Search Console compliant and all URLs resolve correctly.
- Add /blogs/[id] route handler that redirects to Beehiiv URLs (301)
  - Fixes broken links in sitemap reported by code review
  - Allows sitemap to use dealscale.io URLs while redirecting to actual content
  - Handles missing posts gracefully with 404 or redirect to /blogs

- Fix TypeScript errors in sitemap.ts
  - Replace 'as const' on expressions with proper type assertions
  - Use MetadataRoute.Sitemap type assertions for changeFrequency
  - Remove invalid type predicate from supplementalEntries filter

- Add comprehensive sitemap validation tests (25 tests, all passing)
  - URL validation (canonical domain, format, duplicates)
  - Required fields validation (lastModified, changeFrequency, priority)
  - Content coverage (homepage, static pages, RSS feeds, blog posts, etc.)
  - Exclusions validation (no /careers, no external URLs)
  - Priority and change frequency distribution
  - Edge cases handling

This ensures the sitemap is Google Search Console compliant and all URLs resolve correctly.
- Fix import organization in blog route handler
- Remove unused imports from sitemap tests
- Apply Biome formatting fixes to sitemap.ts
@TechWithTy TechWithTy merged commit 9793565 into main Nov 29, 2025
2 of 3 checks passed
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.

2 participants