Repository navigation
feat(nuxt): Send the render start of a cached page to the browser - #26399
Merged
Merged
Conversation
Contributor
size-limit report 📦Compared: adbb6a2 (PR test merge using develop at 1818975) Against: 1818975 (develop) · base run #66291 ✅ Baseline matches: this diff contains only this PR's changes.
|
Contributor
Optional E2E testsSome optional checks were not successful. They do not block the merge. 1 not successful, 62 successful. See the run.
Successful checks
|
mydea
approved these changes
Nov 16, 2026
s1gr1d
enabled stacked auto-merge (squash)
November 16, 2026 13:05
s1gr1d
disabled stacked auto-merge
November 16, 2026 13:06
s1gr1d
force-pushed
the
sig/nuxt-cacheComponents-ticket-20
branch
from
November 16, 2026 14:37
34ede9e to
d2b4e40
Compare
chargome
approved these changes
Nov 16, 2026
|
|
||
| nitroApp.hooks.hook('beforeResponse', updateRouteBeforeResponse); | ||
|
|
||
| nitroApp.hooks.hook('request', recordRequestStart); |
Member
There was a problem hiding this comment.
q: This is not double written bc this also lives in sentry.server.ts right?
Member
Author
There was a problem hiding this comment.
yes, but when using the cloudflare integration, sentry.server.ts needs to be deleted.
s1gr1d
force-pushed
the
sig/nuxt-cacheComponents-ticket-20
branch
2 times, most recently
from
November 16, 2026 15:06
fd00704 to
a7f6839
Compare
Base automatically changed from
sig/sveltekit-cacheComponents-ticket-20
to
develop
November 16, 2026 15:15
Nuxt now writes a `sentry-render-start` meta tag next to `sentry-cache-origin` on cached and prerendered pages, so the browser can set `page.server_rendering.age` on the pageload span. Nitro calls `render:html` only after the whole render, so a `request` hook records the request start, which the tag holds when no span records.
s1gr1d
force-pushed
the
sig/nuxt-cacheComponents-ticket-20
branch
from
November 16, 2026 15:15
a7f6839 to
7d5c505
Compare
s1gr1d
enabled stacked auto-merge (squash)
November 16, 2026 15:18
51 tasks done
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.
Stacked on #26398.
What
Nuxt now writes the
sentry-render-startmeta tag next tosentry-cache-originon cached and prerendered pages. The browser setspage.server_rendering.agefrom it, as in #26397.Why
The tag holds the start of the linked render span. Without a recording span, it holds the request start. Nitro calls
render:htmlonly after the whole render, so a Nitrorequesthook records the start onevent.context. The hook also fires for prerender requests, and a background SWR revalidation sees the context of the request that started it. On Cloudflare, this also gives the right start when the async context is lost.