Repository navigation
fix: add guides hub, restore hub schema, gate dead links - #33
Merged
Merged
Conversation
A live crawl of all 228 sitemap URLs found three defects: - /guides/ was linked from all 20 guides but never built, so it returned 404. Add the hub page from a new guides registry and link it from the footer with /brand-facts/ (both had no inbound links). - BaseLayout had no head slot, so the CollectionPage, BreadcrumbList and WebPage schema in CategoryLayout was dropped on all 13 category hubs. Add the slot. Guides and /calculators/ gain BreadcrumbList. - Two calculator cards pointed at slugs that do not exist. check-internal-links.mjs now also fails on a link whose target page was not built. The new check-breadcrumb-schema.mjs fails on a calculator, hub or guide page with no BreadcrumbList. Both fail on the previous build. robots.txt disallows /cdn-cgi/, where Cloudflare email-protection links return 404 to crawlers. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01LtvCxD865G4AtLvupcVofJ
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
Deploying boring-maths with
|
| Latest commit: |
cfcd8b9
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://a4f01c71.boring-maths.pages.dev |
| Branch Preview URL: | https://seo-guides-hub-and-dead-link.boring-maths.pages.dev |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
A crawl of all 228 sitemap URLs on the live site found three defects. This PR fixes each one at its source and adds a build gate for each.
1.
/guides/returned 404. All 20 guides link to it in their breadcrumb, but the page was never built. This adds the hub page, driven by a new registry insrc/lib/guides.ts. The footer now links to/guides/and/brand-facts/, which had no inbound links.2. Category hubs shipped with no schema.
CategoryLayout.astropasses three JSON-LD scripts withslot="head", butBaseLayout.astrohad noheadslot, so Astro dropped them on all 13 hubs. This adds the slot. The hubs now emit CollectionPage, BreadcrumbList and WebPage. Guides and/calculators/gain BreadcrumbList too.3. Two calculator cards pointed at slugs that do not exist.
cutting-time-calculatorlinked tospeeds-and-feeds-calculator(nowspeeds-feeds-calculator).us-paycheck-calculatorlinked tous-tax-calculator(now the self-employment tax calculator).Also:
robots.txtdisallows/cdn-cgi/, where Cloudflare email-protection links return 404 to crawlers.Gates
scripts/seo/check-internal-links.mjschecked only trailing slashes. It now also fails on a link whose target page was not built.scripts/seo/check-breadcrumb-schema.mjsfails on a calculator, hub or guide page with no BreadcrumbList.tests/seo/guides-registry.test.tskeeps the registry equal to the guide pages on disk.Both build gates fail on the previous build (3 dead targets, 34 pages with no BreadcrumbList) and pass on this one.
Checks
npm run test: 200 files, 1280 tests passnpm run lint: 0 errors (5 warnings, all in files this PR does not touch)npm run format:check: cleannpm run build: 240 pages, all five postbuild gates pass/guides/checked in a browser fromastro previewMerging deploys to production through Cloudflare Pages.
🤖 Generated with Claude Code
https://claude.ai/code/session_01LtvCxD865G4AtLvupcVofJ