da842e167a
### What Client-side transitioning to a page that triggered a loading boundary with async metadata would cause the transition to stall, potentially getting stuck in a refetch loop. ### Why In layout-router, we trigger a "lazy fetch" when we encounter a segment that we don't have cache nodes for. This calls out to the server and suspends until the data fetch is resolved, and applied to the router tree. However after suspending but before updating the client router, we set `childNode.lazyData` to null. When we unsuspend from the server patch action, `childNode.rsc` might still be missing and clearing `lazyData` means we've blown away the reference to the fetch we already had pending, triggering a refetch loop. ### How This removes the logic that mutates the cache node in render, as this is not concurrent safe, and doesn't appear to be needed for anything. Fixes #61117 Closes NEXT-2361 --------- Co-authored-by: Jiachi Liu <inbox@huozhi.im> |
||
---|---|---|
.. | ||
action-after-redirect | ||
middleware-redirect | ||
nested-folder | ||
layout.js | ||
page.js |