Repository navigation
fix(seo): order header rules so asset CORP survives the catch-all - #4
Merged
Merged
Conversation
Vercel merges every matching header rule and the last value for a repeated key wins. The catch-all came last, so its Cross-Origin-Resource-Policy: same-origin overwrote the cross-origin one on /og-image.png and the icons — the card stayed blocked after the first fix. The catch-all now comes first. The test asserts both the value and the ordering, because the ordering is the part that silently broke it. Co-authored-by: arena-agent <297053741+arena-agent@users.noreply.github.com>
imgul
added a commit
that referenced
this pull request
Oct 20, 2026
fix(seo): order header rules so asset CORP survives the catch-all
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.
Follow-up to #3, found by checking the deployed headers instead of trusting the diff.
Vercel merges every matching header rule, and for a repeated key the last value wins. The catch-all
/(.*)rule came last in the array, so itsCross-Origin-Resource-Policy: same-originoverwrote thecross-originI added to/og-image.png,/favicon.icoand the other assets. The deploy went green and the card was still blocked.Fix: the catch-all now comes first, assets after it. Documents keep
same-origin; assets win withcross-origin.The test asserts both the value and the ordering, because ordering is the part that silently broke it:
382 tests, typecheck, build and guard green.