Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions packages/next/src/client/components/layout-router.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -374,6 +374,8 @@ function InnerLayoutRouter({
// The data for this segment is not available, and there's no pending
// navigation that will be able to fulfill it. We need to fetch more from
// the server and patch the cache.
// TODO: Remove this lazy fetch when Segment Cache is enabled once the
// remaining parts of the router are re-implemented to no longer rely on it.

// Check if there's already a pending request.
let lazyData = cacheNode.lazyData
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,9 @@ export function createInitialRouterState({
createHrefFromUrl(location)
: initialCanonicalUrl

addRefreshMarkerToActiveParallelSegments(initialTree, canonicalUrl)
if (!process.env.__NEXT_CLIENT_SEGMENT_CACHE) {
addRefreshMarkerToActiveParallelSegments(initialTree, canonicalUrl)
}

const prefetchCache = new Map<string, PrefetchCacheEntry>()

Expand Down
Loading
Loading