Skip to content

[pull] canary from vercel:canary#1094

Merged
pull[bot] merged 8 commits into
code:canaryfrom
vercel:canary
Jun 2, 2026
Merged

[pull] canary from vercel:canary#1094
pull[bot] merged 8 commits into
code:canaryfrom
vercel:canary

Conversation

@pull
Copy link
Copy Markdown

@pull pull Bot commented Jun 2, 2026

See Commits and Changes for more details.


Created by pull[bot] (v2.0.0-alpha.4)

Can you help keep this open source service alive? 💖 Please sponsor : )

lubieowoce and others added 8 commits June 2, 2026 13:52
I'm about to add 2 new parameters to the `StagedRenderingController`
constructor in #93801, and having them all be positional a `true` or
`null` makes it hard to see what a callsite is actually doing, so i'm
switching it to use an args object for readability.

Extracted from #93801 to make the diff smaller.
### What?

Prevent `hmrRefreshReducer` from being included in production App Router
browser chunks and add regression coverage for the production bundle.

### Why?

`hmrRefreshReducer` is only used by development HMR, but its eager
import from the client reducer caused it to be shipped in optimized
production bundles.

### How?

Load the HMR reducer behind the compile-time development branch in
`ACTION_HMR_REFRESH`, allowing production bundlers to eliminate its
module edge. Extend the production `browser-chunks` test to reject
`hmr-refresh-reducer` sources.

### Verification

- `pnpm --filter=next build`
- `pnpm next build test/e2e/app-dir/hello-world` and verified its
production client chunks contain no `hmrRefreshReducer` or
`hmr-refresh-reducer`
- Red check: restored the eager import and confirmed
`NEXT_TEST_PREFER_OFFLINE=1 pnpm test-start-turbo
test/production/app-dir/browser-chunks/browser-chunks.test.ts` fails on
the new assertion
- `NEXT_TEST_PREFER_OFFLINE=1 pnpm test-start-turbo
test/production/app-dir/browser-chunks/browser-chunks.test.ts`
- `NEXT_TEST_PREFER_OFFLINE=1 pnpm test-start-webpack
test/production/app-dir/browser-chunks/browser-chunks.test.ts`

<!-- NEXT_JS_LLM_PR -->
Remove the `instantNavigationDevToolsToggle` experimental flag and show
the Navigation Inspector whenever `cacheComponents` is enabled. Also
updates docs and test fixtures that referenced the old flag.
Rework the execution order of rewrites.

- before and after Files execution is now clearer - when a source
matches and how the destination resolves
- explicit `dynamic routes` step (similar to Proxy's,
https://nextjs.org/docs/app/api-reference/file-conventions/proxy#execution-order)

---------

Co-authored-by: JJ Kasper <jj@jjsweb.site>
Reframes the Draft Mode guide so the headline is "every Next.js cache
layer is bypassed for the request," not "switch to dynamic rendering."
The previous guide led with an `isEnabled` fork in `getData()`, which
implied users have to branch their fetch code to make caching step
aside. They don't.

Changes:

- Intro lists the bypassed layers (`fetch` cache, `'use cache'`,
`unstable_cache`, ISR response cache).
- Step 3 fetches from a single endpoint with no `isEnabled` branch.
- New Step 4 shows a preview banner + disable handler, which is where
`isEnabled` is actually useful.
- The "Cache Components" example uses `isEnabled` for a UI indicator
instead of branching the fetch URL.
- Two-URL fork demoted to a final section for CMSs that genuinely need
it.
It is possible to call cached functions from the client, under a couple
of conditions.

Rather than introducing this as a pattern now, let's start with a
callout.

Similarly (extending) Server Functions, the client only sees a
reference, no implementation details leak.
Introduce a private env `__NEXT_DISABLE_DEV_OVERLAY_UX ` to skip loading
devtool UX when it's specified
We have no testing infrastructure, unfortunately

<img width="2254" height="1260" alt="Bildschirmfoto 2026-05-28 um 20 29
58"
src="https://github.com/user-attachments/assets/a9f1b646-994d-4417-98d7-160ce5249032"
/>
@pull pull Bot locked and limited conversation to collaborators Jun 2, 2026
@pull pull Bot added the ⤵️ pull label Jun 2, 2026
@pull pull Bot merged commit 0e6f52e into code:canary Jun 2, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants