next.js
9db3c0e5 - [Segment Cache] Send <head> during route prefetch (#72890)

Commit
1 year ago
[Segment Cache] Send <head> during route prefetch (#72890) Based on: - #72874 --- The <head> does not belong to any particular segment; it represents the entire page. Except in the case where two URLs rewrite to the same result, it's very unlikely to benefit from deduplication, so there's no benefit to caching it separately from the route tree. So we'll send it in the same response. Since the head may contain dynamic data, the route tree response may now contain hanging promises, so we'll need to use the same AbortController trick that we use for the segments.
Author
Parents
Loading