Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
N
next.js
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Alex
next.js
Commits
4a3774c2
Unverified
Commit
4a3774c2
authored
Aug 11, 2026
by
Sam Poder
Committed by
GitHub
Aug 11, 2026
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[turbopack] Only use the shared runtime by default on canary (#97208)
This should not be on in 16.3.1.
parent
59aa000d
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
4 deletions
+8
-4
next_config.rs
crates/next-core/src/next_config.rs
+1
-1
define-env.ts
packages/next/src/build/define-env.ts
+3
-2
config-shared.ts
packages/next/src/server/config-shared.ts
+4
-1
No files found.
crates/next-core/src/next_config.rs
View file @
4a3774c2
...
@@ -2645,7 +2645,7 @@ impl NextConfig {
...
@@ -2645,7 +2645,7 @@ impl NextConfig {
// The shared runtime / inlined bootstrap is a production-only optimization; in
// The shared runtime / inlined bootstrap is a production-only optimization; in
// development the per-route runtime is required for HMR.
// development the per-route runtime is required for HMR.
NextMode
::
Development
=>
false
,
NextMode
::
Development
=>
false
,
NextMode
::
Build
=>
self
.experimental.turbopack_shared_runtime
.unwrap_or
(
tru
e
),
NextMode
::
Build
=>
self
.experimental.turbopack_shared_runtime
.unwrap_or
(
fals
e
),
}))
}))
}
}
...
...
packages/next/src/build/define-env.ts
View file @
4a3774c2
...
@@ -169,8 +169,9 @@ export function getDefineEnv({
...
@@ -169,8 +169,9 @@ export function getDefineEnv({
'process.env.__NEXT_APP_NAV_FAIL_HANDLING'
:
Boolean
(
'process.env.__NEXT_APP_NAV_FAIL_HANDLING'
:
Boolean
(
config
.
experimental
.
appNavFailHandling
config
.
experimental
.
appNavFailHandling
),
),
'process.env.__NEXT_TURBOPACK_SHARED_RUNTIME'
:
'process.env.__NEXT_TURBOPACK_SHARED_RUNTIME'
:
Boolean
(
config
.
experimental
.
turbopackSharedRuntime
!==
false
,
config
.
experimental
.
turbopackSharedRuntime
),
'process.env.__NEXT_CACHE_COMPONENTS'
:
isCacheComponentsEnabled
,
'process.env.__NEXT_CACHE_COMPONENTS'
:
isCacheComponentsEnabled
,
'process.env.__NEXT_EXPERIMENTAL_CACHED_NAVIGATIONS'
:
Boolean
(
'process.env.__NEXT_EXPERIMENTAL_CACHED_NAVIGATIONS'
:
Boolean
(
config
.
experimental
.
cachedNavigations
config
.
experimental
.
cachedNavigations
...
...
packages/next/src/server/config-shared.ts
View file @
4a3774c2
...
@@ -12,6 +12,7 @@ import type { NextParsedUrlQuery } from './request-meta'
...
@@ -12,6 +12,7 @@ import type { NextParsedUrlQuery } from './request-meta'
import
type
{
SizeLimit
}
from
'../types'
import
type
{
SizeLimit
}
from
'../types'
import
type
{
SupportedTestRunners
}
from
'../cli/next-test'
import
type
{
SupportedTestRunners
}
from
'../cli/next-test'
import
{
INFINITE_CACHE
}
from
'../lib/constants'
import
{
INFINITE_CACHE
}
from
'../lib/constants'
import
{
isStableBuild
}
from
'../shared/lib/errors/canary-only-config-error'
import
type
{
FallbackRouteParam
}
from
'../build/static-paths/types'
import
type
{
FallbackRouteParam
}
from
'../build/static-paths/types'
import
type
{
MemoryEvictionMode
}
from
'../build/swc/types'
import
type
{
MemoryEvictionMode
}
from
'../build/swc/types'
import
type
{
CacheLife
}
from
'./use-cache/cache-life'
import
type
{
CacheLife
}
from
'./use-cache/cache-life'
...
@@ -794,7 +795,8 @@ export interface ExperimentalConfig {
...
@@ -794,7 +795,8 @@ export interface ExperimentalConfig {
/**
/**
* Share the browser runtime across routes in a single `runtime.js` asset and inline the
* Share the browser runtime across routes in a single `runtime.js` asset and inline the
* per-route chunk-group bootstrap into the HTML, dropping the per-route runtime. Defaults to
* per-route chunk-group bootstrap into the HTML, dropping the per-route runtime. Defaults to
* true. Only applies to production builds; has no effect in development mode.
* true on canary releases and false on stable releases. Only applies to production builds; has
* no effect in development mode.
*/
*/
turbopackSharedRuntime
?:
boolean
turbopackSharedRuntime
?:
boolean
...
@@ -2291,6 +2293,7 @@ export const defaultConfig = Object.freeze({
...
@@ -2291,6 +2293,7 @@ export const defaultConfig = Object.freeze({
turbopackFileSystemCacheForBuild
:
true
,
turbopackFileSystemCacheForBuild
:
true
,
turbopackInferModuleSideEffects
:
true
,
turbopackInferModuleSideEffects
:
true
,
turbopackPluginRuntimeStrategy
:
'childProcesses'
,
turbopackPluginRuntimeStrategy
:
'childProcesses'
,
turbopackSharedRuntime
:
!
isStableBuild
(),
},
},
htmlLimitedBots
:
undefined
,
htmlLimitedBots
:
undefined
,
bundlePagesRouterDependencies
:
false
,
bundlePagesRouterDependencies
:
false
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment