What's Changed
New Features
- Added support for inline CSS parity in App Router
- Implemented
compiler.defineandcompiler.defineServerconfiguration options - Added
compiler.removeConsolebuild option to strip console statements
Bug Fixes
App Router
- Fixed static-sibling info inclusion in SSR responses
- Fixed caching for pages with
revalidate=Infinityorrevalidate=false - Fixed module-only Vite reference errors now properly treated as action-not-found
- Fixed
forbidden()andunauthorized()to properly escalate past intermediate layouts - Fixed client prefetch cache to honor
experimental.staleTimesconfiguration - Fixed routing to treat
@childrenas transparent so explicit pages win over catchalls - Fixed action Set-Cookie header deduplication by name
- Fixed
icons.othermetadata to accept single descriptor format - Fixed
draftMode()reads inside cache scopes - Fixed cookie and header propagation from server actions without JavaScript
- Fixed global-not-found chunk isolation to prevent CSS cascade issues
- Fixed
unstable_rootParamspropagation to actions and route handlers - Fixed spacing in streamed error meta tags
- Fixed autoscroll preservation across page refreshes
- Fixed
updateTagto throw proper error when called outside Server Actions - Fixed source identity preservation for intercepted renders
- Fixed default autoscroll page target behavior
Pages Router
- Fixed
Document.getInitialPropsinvocation so document props reach SSR - Fixed app route detection during prefetch operations
- Fixed custom
pages/500rendering on SSR errors - Fixed non-serializable
getStaticProps/getServerSidePropserror handling - Fixed page script emission with defer attribute in
<head>by default - Fixed
useParamssnapshot stabilization for SSR - Fixed static page responses to return 405 with proper
Allowheader for invalid methods - Fixed 404 responses for invalid
_next/staticrequests in worker deployment
General
- Fixed Next.js script stylesheets to emit proper
<link rel="stylesheet">tags - Fixed
unstable_retryto throw proper Pages Router parity error - Fixed webpack loader side effects to apply
process.envmutations - Fixed build process to inline
process.env.NEXT_DEPLOYMENT_IDfor client and worker bundles - Fixed OpenTelemetry to inject
experimental.clientTraceMetadatainto SSR head - Fixed build to forward
pageExtensionsto Vite resolve extensions - Fixed middleware to stop merging original query into rewrite targets
- Fixed Link component
href/onClickforwarding inlegacyBehaviormode - Fixed React DOM prop name translation to HTML attributes in hoisted scripts
- Fixed route handler Set-Cookie default
Path=/when merging mutable cookies - Fixed routing precedence when both
pages/_foo.tsxandapp/directory exist - Fixed development favicon.ico handling to avoid expensive 404 renders
Performance
- Moved
normalizePathSeparatorsutility to shared path utils - Reused
normalizePathSeparatorsfor static file cache path handling
Internal / Chores
- Added comprehensive test coverage for Link component onClick/preventDefault behavior
- Added regression tests for API route dispatch with middleware
- Added trailing slash enforcement tests for App Router
- Added regression tests for URL-encoded CSS paths
- Added shallow Router.push redirect bypass tests
- Added edge runtime and OG image API route tests
- Added metadata regression test for dynamic icon hrefs
- Added Link component OnNavigate fixture tests
- Added form action regression tests
- Added various other regression and edge case test coverage