You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix: add backwards compat for middleware → proxy field renames (#85183)
### What?
These config keys were recently soft-renamed with forward compatibility
on the _resolved_ config object:
- `experimental.proxyPrefetch` → `experimental.middlewarePrefetch`
- `experimental.externalProxyRewritesResolve` →
`experimental.externalMiddlewareRewritesResolve`
- `skipProxyUrlNormalize` → `skipMiddlewareUrlNormalize`
But there was no backwards compatibility on the resolved, which is
(arguably) an undocumented breaking change.
### Why?
This avoids introducing a last-minute breaking change for providers and
other integrations that read the the `.next/` build output files (which
is necessary until we all move to the upcoming [Adapter
API](#77740).
### How?
When a new `proxy` config key is set but the old `middleware` name is
not, copy the value to the old name on the *resolved* config object.
This also adds test coverage for both the existing forward compat
(old→new) and the new backwards compat (new→old).
Co-authored-by: JJ Kasper <jj@jjsweb.site>
0 commit comments