Fix production metadata and header bugs - #2024
Merged
Merged
Conversation
- Stop shipping the bundle visualizer report to /stats (opt-in via ANALYZE=1, written to .astro/) - Resolve JSON-LD images with new URL() so protocol-relative images don't double the host - Carry _headers (CSP, Link, Permissions-Policy) onto Markdown responses; add Vary: Accept to negotiable HTML - Emit git-based dateModified / article:modified_time on posts, sharing the sitemap lastmod index - Make root-relative links absolute in per-post .md agent files - RSS author as "email (Name)"; index.md calls the feed RSS, not Atom - Remove the /feed/index.xml route; _redirects already 301s it, and the build wrote a meta-refresh page to a .xml path Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
Production bugs found in a general audit. Each one was confirmed on the live site or in a local build.
/statswas public. The bundle visualizer wrotestats.htmlintodist-astro/, so it deployed;ben.balter.com/statsreturns 200 today. It's now opt-in (ANALYZE=1) and writes to.astro/.https://ben.balter.com//ben.balter.com/wp-content/...because the old check only looked for anhttpprefix. It now usesnew URL(image, site). Added a test.Vary: Accept.dateModified. Posts now emit a git-baseddateModified/article:modified_time, reusing the sitemap's lastmod index, which skips sweep commits. Previously it always equaleddatePublished. 57 posts pick up a modified date..mdagent files. Root-relative links are now absolute; 23 posts were affected. This adds anabsolutizeMarkdownLinksutil with tests.<author>is nowemail (Name), as RSS 2.0 requires.index.mdcalled the feed "Atom"; it now says RSS./feed/index.xmlroute._redirectsalready returns a 301 (checked live), and the route only made the build write a meta-refresh HTML page to a.xmlpath.Verification
npm run check: clean.SKIP_PDF=1 npm run build: nostats.htmlin the output, no doubled host, and no](/left in the.mdfiles.🤖 Generated with Claude Code