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
62bc131f
Unverified
Commit
62bc131f
authored
Aug 06, 2025
by
Sebastian "Sebbie" Silbermann
Committed by
GitHub
Aug 06, 2025
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[devtools] Make state read-only in types (#82396)
parent
373f3e1d
Hide whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
75 additions
and
61 deletions
+75
-61
call-stack.tsx
...devtools/dev-overlay/components/call-stack/call-stack.tsx
+1
-1
error-overlay-call-stack.tsx
...ors/error-overlay-call-stack/error-overlay-call-stack.tsx
+1
-1
error-overlay-nav.stories.tsx
...ts/errors/error-overlay-nav/error-overlay-nav.stories.tsx
+3
-0
error-overlay-pagination.stories.tsx
...r-overlay-pagination/error-overlay-pagination.stories.tsx
+3
-0
restart-server-button.tsx
...ts/errors/error-overlay-toolbar/restart-server-button.tsx
+1
-1
errors.stories.tsx
...rc/next-devtools/dev-overlay/container/errors.stories.tsx
+16
-14
render-error.tsx
...ools/dev-overlay/container/runtime-error/render-error.tsx
+2
-2
shared.ts
packages/next/src/next-devtools/dev-overlay/shared.ts
+26
-27
errors.ts
...es/next/src/next-devtools/dev-overlay/storybook/errors.ts
+10
-0
get-error-by-type.ts
.../src/next-devtools/dev-overlay/utils/get-error-by-type.ts
+7
-10
shared.ts
packages/next/src/next-devtools/server/shared.ts
+1
-1
stack-frame.ts
packages/next/src/next-devtools/shared/stack-frame.ts
+2
-2
middleware-turbopack.ts
packages/next/src/server/dev/middleware-turbopack.ts
+1
-1
middleware-webpack.ts
packages/next/src/server/dev/middleware-webpack.ts
+1
-1
No files found.
packages/next/src/next-devtools/dev-overlay/components/call-stack/call-stack.tsx
View file @
62bc131f
...
@@ -10,7 +10,7 @@ export function CallStack({
...
@@ -10,7 +10,7 @@ export function CallStack({
ignoredFramesTally
,
ignoredFramesTally
,
onToggleIgnoreList
,
onToggleIgnoreList
,
}:
{
}:
{
frames
:
OriginalStackFrame
[]
frames
:
readonly
OriginalStackFrame
[]
isIgnoreListOpen
:
boolean
isIgnoreListOpen
:
boolean
ignoredFramesTally
:
number
ignoredFramesTally
:
number
onToggleIgnoreList
:
()
=>
void
onToggleIgnoreList
:
()
=>
void
...
...
packages/next/src/next-devtools/dev-overlay/components/errors/error-overlay-call-stack/error-overlay-call-stack.tsx
View file @
62bc131f
...
@@ -3,7 +3,7 @@ import { useMemo, useState, useRef } from 'react'
...
@@ -3,7 +3,7 @@ import { useMemo, useState, useRef } from 'react'
import
{
CallStack
}
from
'../../call-stack/call-stack'
import
{
CallStack
}
from
'../../call-stack/call-stack'
interface
CallStackProps
{
interface
CallStackProps
{
frames
:
OriginalStackFrame
[]
frames
:
readonly
OriginalStackFrame
[]
dialogResizerRef
:
React
.
RefObject
<
HTMLDivElement
|
null
>
dialogResizerRef
:
React
.
RefObject
<
HTMLDivElement
|
null
>
}
}
...
...
packages/next/src/next-devtools/dev-overlay/components/errors/error-overlay-nav/error-overlay-nav.stories.tsx
View file @
62bc131f
...
@@ -21,6 +21,7 @@ export const Default: Story = {
...
@@ -21,6 +21,7 @@ export const Default: Story = {
runtime
:
true
,
runtime
:
true
,
error
:
new
Error
(
'First error message'
),
error
:
new
Error
(
'First error message'
),
frames
:
()
=>
Promise
.
resolve
([]),
frames
:
()
=>
Promise
.
resolve
([]),
componentStackFrames
:
undefined
,
type
:
'runtime'
,
type
:
'runtime'
,
},
},
{
{
...
@@ -28,6 +29,7 @@ export const Default: Story = {
...
@@ -28,6 +29,7 @@ export const Default: Story = {
runtime
:
true
,
runtime
:
true
,
error
:
new
Error
(
'Second error message'
),
error
:
new
Error
(
'Second error message'
),
frames
:
()
=>
Promise
.
resolve
([]),
frames
:
()
=>
Promise
.
resolve
([]),
componentStackFrames
:
undefined
,
type
:
'runtime'
,
type
:
'runtime'
,
},
},
{
{
...
@@ -35,6 +37,7 @@ export const Default: Story = {
...
@@ -35,6 +37,7 @@ export const Default: Story = {
runtime
:
true
,
runtime
:
true
,
error
:
new
Error
(
'Third error message'
),
error
:
new
Error
(
'Third error message'
),
frames
:
()
=>
Promise
.
resolve
([]),
frames
:
()
=>
Promise
.
resolve
([]),
componentStackFrames
:
undefined
,
type
:
'runtime'
,
type
:
'runtime'
,
},
},
],
],
...
...
packages/next/src/next-devtools/dev-overlay/components/errors/error-overlay-pagination/error-overlay-pagination.stories.tsx
View file @
62bc131f
...
@@ -22,6 +22,7 @@ const mockErrors: ReadyRuntimeError[] = [
...
@@ -22,6 +22,7 @@ const mockErrors: ReadyRuntimeError[] = [
runtime
:
true
as
const
,
runtime
:
true
as
const
,
error
:
new
Error
(
'First error'
),
error
:
new
Error
(
'First error'
),
frames
:
()
=>
Promise
.
resolve
([]),
frames
:
()
=>
Promise
.
resolve
([]),
componentStackFrames
:
undefined
,
type
:
'runtime'
,
type
:
'runtime'
,
},
},
{
{
...
@@ -29,6 +30,7 @@ const mockErrors: ReadyRuntimeError[] = [
...
@@ -29,6 +30,7 @@ const mockErrors: ReadyRuntimeError[] = [
runtime
:
true
as
const
,
runtime
:
true
as
const
,
error
:
new
Error
(
'Second error'
),
error
:
new
Error
(
'Second error'
),
frames
:
()
=>
Promise
.
resolve
([]),
frames
:
()
=>
Promise
.
resolve
([]),
componentStackFrames
:
undefined
,
type
:
'runtime'
,
type
:
'runtime'
,
},
},
{
{
...
@@ -36,6 +38,7 @@ const mockErrors: ReadyRuntimeError[] = [
...
@@ -36,6 +38,7 @@ const mockErrors: ReadyRuntimeError[] = [
runtime
:
true
as
const
,
runtime
:
true
as
const
,
error
:
new
Error
(
'Third error'
),
error
:
new
Error
(
'Third error'
),
frames
:
()
=>
Promise
.
resolve
([]),
frames
:
()
=>
Promise
.
resolve
([]),
componentStackFrames
:
undefined
,
type
:
'runtime'
,
type
:
'runtime'
,
},
},
]
]
...
...
packages/next/src/next-devtools/dev-overlay/components/errors/error-overlay-toolbar/restart-server-button.tsx
View file @
62bc131f
...
@@ -51,7 +51,7 @@ export function usePersistentCacheErrorDetection({
...
@@ -51,7 +51,7 @@ export function usePersistentCacheErrorDetection({
errors
,
errors
,
dispatch
,
dispatch
,
}:
{
}:
{
errors
:
SupportedErrorEvent
[]
errors
:
readonly
SupportedErrorEvent
[]
dispatch
:
OverlayDispatch
dispatch
:
OverlayDispatch
})
{
})
{
useEffect
(()
=>
{
useEffect
(()
=>
{
...
...
packages/next/src/next-devtools/dev-overlay/container/errors.stories.tsx
View file @
62bc131f
...
@@ -70,20 +70,6 @@ export const WithHydrationWarning: Story = {
...
@@ -70,20 +70,6 @@ export const WithHydrationWarning: Story = {
- <p> hello world and welcome to my amazing website with lots of content hello world and welcome to my amazing website with lots of content </p>
- <p> hello world and welcome to my amazing website with lots of content hello world and welcome to my amazing website with lots of content </p>
+ <div> hello world and welcome to my amazing website with lots of content hello world and welcome to my amazing website with lots of content </div>`
,
+ <div> hello world and welcome to my amazing website with lots of content hello world and welcome to my amazing website with lots of content </div>`
,
},
},
componentStackFrames
:
[
{
component
:
'MyComponent'
,
file
:
'app/page.tsx'
,
lineNumber
:
10
,
columnNumber
:
5
,
},
{
component
:
'ParentComponent'
,
file
:
'app/layout.tsx'
,
lineNumber
:
20
,
columnNumber
:
3
,
},
],
}),
}),
frames
:
()
=>
frames
:
()
=>
Promise
.
resolve
([
Promise
.
resolve
([
...
@@ -103,6 +89,22 @@ export const WithHydrationWarning: Story = {
...
@@ -103,6 +89,22 @@ export const WithHydrationWarning: Story = {
},
},
},
},
]),
]),
componentStackFrames
:
[
{
component
:
'MyComponent'
,
file
:
'app/page.tsx'
,
line1
:
10
,
column1
:
5
,
canOpenInEditor
:
true
,
},
{
component
:
'ParentComponent'
,
file
:
'app/layout.tsx'
,
line1
:
20
,
column1
:
3
,
canOpenInEditor
:
true
,
},
],
type
:
'runtime'
,
type
:
'runtime'
,
},
},
],
],
...
...
packages/next/src/next-devtools/dev-overlay/container/runtime-error/render-error.tsx
View file @
62bc131f
...
@@ -12,8 +12,8 @@ import { usePersistentCacheErrorDetection } from '../../components/errors/error-
...
@@ -12,8 +12,8 @@ import { usePersistentCacheErrorDetection } from '../../components/errors/error-
export
type
SupportedErrorEvent
=
{
export
type
SupportedErrorEvent
=
{
id
:
number
id
:
number
error
:
Error
error
:
Error
frames
:
StackFrame
[]
frames
:
readonly
StackFrame
[]
componentStackFrames
?:
ComponentStackFrame
[]
componentStackFrames
?:
readonly
ComponentStackFrame
[]
type
:
'runtime'
|
'recoverable'
|
'console'
type
:
'runtime'
|
'recoverable'
|
'console'
}
}
...
...
packages/next/src/next-devtools/dev-overlay/shared.ts
View file @
62bc131f
...
@@ -39,41 +39,40 @@ type FastRefreshState =
...
@@ -39,41 +39,40 @@ type FastRefreshState =
/** No refresh in progress. */
/** No refresh in progress. */
|
{
type
:
'idle'
}
|
{
type
:
'idle'
}
/** The refresh process has been triggered, but the new code has not been executed yet. */
/** The refresh process has been triggered, but the new code has not been executed yet. */
|
{
type
:
'pending'
;
errors
:
SupportedErrorEvent
[]
}
|
{
type
:
'pending'
;
errors
:
readonly
SupportedErrorEvent
[]
}
export
interface
OverlayState
{
export
interface
OverlayState
{
nextId
:
number
readonly
nextId
:
number
buildError
:
string
|
null
readonly
buildError
:
string
|
null
errors
:
SupportedErrorEvent
[]
readonly
errors
:
readonly
SupportedErrorEvent
[]
refreshState
:
FastRefreshState
re
adonly
re
freshState
:
FastRefreshState
versionInfo
:
VersionInfo
readonly
versionInfo
:
VersionInfo
notFound
:
boolean
readonly
notFound
:
boolean
buildingIndicator
:
boolean
readonly
buildingIndicator
:
boolean
renderingIndicator
:
boolean
re
adonly
re
nderingIndicator
:
boolean
staticIndicator
:
boolean
readonly
staticIndicator
:
boolean
showIndicator
:
boolean
readonly
showIndicator
:
boolean
disableDevIndicator
:
boolean
readonly
disableDevIndicator
:
boolean
/** Whether to show the restart server button in the panel UI. Currently
/** Whether to show the restart server button in the panel UI. Currently
* only used when Turbopack + Persistent Cache is enabled.
* only used when Turbopack + Persistent Cache is enabled.
*/
*/
showRestartServerButton
:
boolean
readonly
showRestartServerButton
:
boolean
debugInfo
:
DebugInfo
readonly
debugInfo
:
DebugInfo
routerType
:
'pages'
|
'app'
r
eadonly
r
outerType
:
'pages'
|
'app'
/** This flag is used to handle the Error Overlay state in the "old" overlay.
/** This flag is used to handle the Error Overlay state in the "old" overlay.
* In the DevTools panel, this value will used for the "Error Overlay Mode"
* In the DevTools panel, this value will used for the "Error Overlay Mode"
* which is viewing the "Issues Tab" as a fullscreen.
* which is viewing the "Issues Tab" as a fullscreen.
*/
*/
isErrorOverlayOpen
:
boolean
readonly
isErrorOverlayOpen
:
boolean
devToolsPosition
:
Corners
readonly
devToolsPosition
:
Corners
devToolsPanelPosition
:
Record
<
DevtoolsPanelName
,
Corners
>
readonly
devToolsPanelPosition
:
Readonly
<
Record
<
DevtoolsPanelName
,
Corners
>>
devToolsPanelSize
:
Record
<
readonly
devToolsPanelSize
:
Readonly
<
DevtoolsPanelName
,
Record
<
DevtoolsPanelName
,
{
width
:
number
;
height
:
number
}
>
{
width
:
number
;
height
:
number
}
>
>
scale
:
number
readonly
scale
:
number
page
:
string
readonly
page
:
string
theme
:
'light'
|
'dark'
|
'system'
readonly
theme
:
'light'
|
'dark'
|
'system'
hideShortcut
:
string
|
null
readonly
hideShortcut
:
string
|
null
}
}
type
DevtoolsPanelName
=
string
type
DevtoolsPanelName
=
string
export
type
OverlayDispatch
=
React
.
Dispatch
<
DispatcherEvent
>
export
type
OverlayDispatch
=
React
.
Dispatch
<
DispatcherEvent
>
...
@@ -325,10 +324,10 @@ export function useErrorOverlayReducer(
...
@@ -325,10 +324,10 @@ export function useErrorOverlayReducer(
isRecoverableError
:
(
error
:
Error
)
=>
boolean
isRecoverableError
:
(
error
:
Error
)
=>
boolean
)
{
)
{
function
pushErrorFilterDuplicates
(
function
pushErrorFilterDuplicates
(
events
:
SupportedErrorEvent
[],
events
:
readonly
SupportedErrorEvent
[],
id
:
number
,
id
:
number
,
error
:
Error
error
:
Error
):
SupportedErrorEvent
[]
{
):
readonly
SupportedErrorEvent
[]
{
const
componentStack
=
getComponentStack
(
error
)
const
componentStack
=
getComponentStack
(
error
)
const
componentStackFrames
=
const
componentStackFrames
=
componentStack
===
undefined
componentStack
===
undefined
...
...
packages/next/src/next-devtools/dev-overlay/storybook/errors.ts
View file @
62bc131f
...
@@ -126,6 +126,7 @@ export const runtimeErrors: ReadyRuntimeError[] = [
...
@@ -126,6 +126,7 @@ export const runtimeErrors: ReadyRuntimeError[] = [
},
},
...
Array
(
20
).
fill
(
ignoredFrame
),
...
Array
(
20
).
fill
(
ignoredFrame
),
]),
]),
componentStackFrames
:
undefined
,
type
:
'runtime'
,
type
:
'runtime'
,
},
},
{
{
...
@@ -144,6 +145,7 @@ export const runtimeErrors: ReadyRuntimeError[] = [
...
@@ -144,6 +145,7 @@ export const runtimeErrors: ReadyRuntimeError[] = [
originalCodeFrame
:
originalCodeFrame
(
'Second error message'
),
originalCodeFrame
:
originalCodeFrame
(
'Second error message'
),
},
},
]),
]),
componentStackFrames
:
undefined
,
type
:
'console'
,
type
:
'console'
,
},
},
{
{
...
@@ -162,6 +164,7 @@ export const runtimeErrors: ReadyRuntimeError[] = [
...
@@ -162,6 +164,7 @@ export const runtimeErrors: ReadyRuntimeError[] = [
originalCodeFrame
:
originalCodeFrame
(
'Third error message'
),
originalCodeFrame
:
originalCodeFrame
(
'Third error message'
),
},
},
]),
]),
componentStackFrames
:
undefined
,
type
:
'recoverable'
,
type
:
'recoverable'
,
},
},
{
{
...
@@ -180,6 +183,7 @@ export const runtimeErrors: ReadyRuntimeError[] = [
...
@@ -180,6 +183,7 @@ export const runtimeErrors: ReadyRuntimeError[] = [
originalCodeFrame
:
originalCodeFrame
(
'typeof window !== undefined'
),
originalCodeFrame
:
originalCodeFrame
(
'typeof window !== undefined'
),
},
},
]),
]),
componentStackFrames
:
undefined
,
type
:
'runtime'
,
type
:
'runtime'
,
},
},
{
{
...
@@ -204,6 +208,7 @@ export const runtimeErrors: ReadyRuntimeError[] = [
...
@@ -204,6 +208,7 @@ export const runtimeErrors: ReadyRuntimeError[] = [
originalCodeFrame
:
originalCodeFrame
(
'Fifth error message'
),
originalCodeFrame
:
originalCodeFrame
(
'Fifth error message'
),
},
},
]),
]),
componentStackFrames
:
undefined
,
type
:
'console'
,
type
:
'console'
,
},
},
{
{
...
@@ -222,6 +227,7 @@ export const runtimeErrors: ReadyRuntimeError[] = [
...
@@ -222,6 +227,7 @@ export const runtimeErrors: ReadyRuntimeError[] = [
originalCodeFrame
:
originalCodeFrame
(
'Sixth error message'
),
originalCodeFrame
:
originalCodeFrame
(
'Sixth error message'
),
},
},
]),
]),
componentStackFrames
:
undefined
,
type
:
'recoverable'
,
type
:
'recoverable'
,
},
},
{
{
...
@@ -240,6 +246,7 @@ export const runtimeErrors: ReadyRuntimeError[] = [
...
@@ -240,6 +246,7 @@ export const runtimeErrors: ReadyRuntimeError[] = [
originalCodeFrame
:
originalCodeFrame
(
'Sixth error message'
),
originalCodeFrame
:
originalCodeFrame
(
'Sixth error message'
),
},
},
]),
]),
componentStackFrames
:
undefined
,
type
:
'runtime'
,
type
:
'runtime'
,
},
},
{
{
...
@@ -258,6 +265,7 @@ export const runtimeErrors: ReadyRuntimeError[] = [
...
@@ -258,6 +265,7 @@ export const runtimeErrors: ReadyRuntimeError[] = [
originalCodeFrame
:
originalCodeFrame
(
'Eighth error message'
),
originalCodeFrame
:
originalCodeFrame
(
'Eighth error message'
),
},
},
]),
]),
componentStackFrames
:
undefined
,
type
:
'runtime'
,
type
:
'runtime'
,
},
},
{
{
...
@@ -276,6 +284,7 @@ export const runtimeErrors: ReadyRuntimeError[] = [
...
@@ -276,6 +284,7 @@ export const runtimeErrors: ReadyRuntimeError[] = [
originalCodeFrame
:
originalCodeFrame
(
'Ninth error message'
),
originalCodeFrame
:
originalCodeFrame
(
'Ninth error message'
),
},
},
]),
]),
componentStackFrames
:
undefined
,
type
:
'runtime'
,
type
:
'runtime'
,
},
},
{
{
...
@@ -294,6 +303,7 @@ export const runtimeErrors: ReadyRuntimeError[] = [
...
@@ -294,6 +303,7 @@ export const runtimeErrors: ReadyRuntimeError[] = [
originalCodeFrame
:
originalCodeFrame
(
'Tenth error message'
),
originalCodeFrame
:
originalCodeFrame
(
'Tenth error message'
),
},
},
]),
]),
componentStackFrames
:
undefined
,
type
:
'runtime'
,
type
:
'runtime'
,
},
},
]
]
packages/next/src/next-devtools/dev-overlay/utils/get-error-by-type.ts
View file @
62bc131f
...
@@ -9,14 +9,16 @@ export type ReadyRuntimeError = {
...
@@ -9,14 +9,16 @@ export type ReadyRuntimeError = {
id
:
number
id
:
number
runtime
:
true
runtime
:
true
error
:
Error
&
{
environmentName
?:
string
}
error
:
Error
&
{
environmentName
?:
string
}
frames
:
OriginalStackFrame
[]
|
(()
=>
Promise
<
OriginalStackFrame
[]
>
)
frames
:
componentStackFrames
?:
ComponentStackFrame
[]
|
readonly
OriginalStackFrame
[]
|
(()
=>
Promise
<
readonly
OriginalStackFrame
[]
>
)
componentStackFrames
:
readonly
ComponentStackFrame
[]
|
undefined
type
:
'runtime'
|
'console'
|
'recoverable'
type
:
'runtime'
|
'console'
|
'recoverable'
}
}
export
const
useFrames
=
(
export
const
useFrames
=
(
error
:
ReadyRuntimeError
|
null
error
:
ReadyRuntimeError
|
null
):
OriginalStackFrame
[]
=>
{
):
readonly
OriginalStackFrame
[]
=>
{
if
(
!
error
)
return
[]
if
(
!
error
)
return
[]
if
(
'use'
in
React
)
{
if
(
'use'
in
React
)
{
...
@@ -28,7 +30,7 @@ export const useFrames = (
...
@@ -28,7 +30,7 @@ export const useFrames = (
)
)
}
}
return
React
.
use
((
frames
as
()
=>
Promise
<
OriginalStackFrame
[]
>
)())
return
React
.
use
((
frames
as
()
=>
Promise
<
readonly
OriginalStackFrame
[]
>
)())
}
else
{
}
else
{
if
(
!
Array
.
isArray
(
error
.
frames
))
{
if
(
!
Array
.
isArray
(
error
.
frames
))
{
throw
new
Error
(
throw
new
Error
(
...
@@ -49,6 +51,7 @@ export async function getErrorByType(
...
@@ -49,6 +51,7 @@ export async function getErrorByType(
runtime
:
true
,
runtime
:
true
,
error
:
event
.
error
,
error
:
event
.
error
,
type
:
event
.
type
,
type
:
event
.
type
,
componentStackFrames
:
event
.
componentStackFrames
,
}
as
const
}
as
const
if
(
'use'
in
React
)
{
if
(
'use'
in
React
)
{
...
@@ -63,9 +66,6 @@ export async function getErrorByType(
...
@@ -63,9 +66,6 @@ export async function getErrorByType(
)
)
}),
}),
}
}
if
(
event
.
componentStackFrames
!==
undefined
)
{
readyRuntimeError
.
componentStackFrames
=
event
.
componentStackFrames
}
return
readyRuntimeError
return
readyRuntimeError
}
else
{
}
else
{
const
readyRuntimeError
:
ReadyRuntimeError
=
{
const
readyRuntimeError
:
ReadyRuntimeError
=
{
...
@@ -77,9 +77,6 @@ export async function getErrorByType(
...
@@ -77,9 +77,6 @@ export async function getErrorByType(
isAppDir
isAppDir
),
),
}
}
if
(
event
.
componentStackFrames
!==
undefined
)
{
readyRuntimeError
.
componentStackFrames
=
event
.
componentStackFrames
}
return
readyRuntimeError
return
readyRuntimeError
}
}
}
}
...
...
packages/next/src/next-devtools/server/shared.ts
View file @
62bc131f
...
@@ -10,7 +10,7 @@ export interface IgnorableStackFrame extends StackFrame {
...
@@ -10,7 +10,7 @@ export interface IgnorableStackFrame extends StackFrame {
}
}
export
interface
OriginalStackFramesRequest
{
export
interface
OriginalStackFramesRequest
{
frames
:
StackFrame
[]
frames
:
readonly
StackFrame
[]
isServer
:
boolean
isServer
:
boolean
isEdgeServer
:
boolean
isEdgeServer
:
boolean
isAppDirectory
:
boolean
isAppDirectory
:
boolean
...
...
packages/next/src/next-devtools/shared/stack-frame.ts
View file @
62bc131f
...
@@ -80,10 +80,10 @@ function getOriginalStackFrame(
...
@@ -80,10 +80,10 @@ function getOriginalStackFrame(
}
}
export
async
function
getOriginalStackFrames
(
export
async
function
getOriginalStackFrames
(
frames
:
StackFrame
[],
frames
:
readonly
StackFrame
[],
type
:
'server'
|
'edge-server'
|
null
,
type
:
'server'
|
'edge-server'
|
null
,
isAppDir
:
boolean
isAppDir
:
boolean
):
Promise
<
OriginalStackFrame
[]
>
{
):
Promise
<
readonly
OriginalStackFrame
[]
>
{
const
req
:
OriginalStackFramesRequest
=
{
const
req
:
OriginalStackFramesRequest
=
{
frames
,
frames
,
isServer
:
type
===
'server'
,
isServer
:
type
===
'server'
,
...
...
packages/next/src/server/dev/middleware-turbopack.ts
View file @
62bc131f
...
@@ -482,7 +482,7 @@ export async function getOriginalStackFrames({
...
@@ -482,7 +482,7 @@ export async function getOriginalStackFrames({
}:
{
}:
{
project
:
Project
project
:
Project
projectPath
:
string
projectPath
:
string
frames
:
StackFrame
[]
frames
:
readonly
StackFrame
[]
isServer
:
boolean
isServer
:
boolean
isEdgeServer
:
boolean
isEdgeServer
:
boolean
isAppDirectory
:
boolean
isAppDirectory
:
boolean
...
...
packages/next/src/server/dev/middleware-webpack.ts
View file @
62bc131f
...
@@ -384,7 +384,7 @@ export async function getOriginalStackFrames({
...
@@ -384,7 +384,7 @@ export async function getOriginalStackFrames({
isServer
:
boolean
isServer
:
boolean
isEdgeServer
:
boolean
isEdgeServer
:
boolean
isAppDirectory
:
boolean
isAppDirectory
:
boolean
frames
:
StackFrame
[]
frames
:
readonly
StackFrame
[]
clientStats
:
()
=>
webpack
.
Stats
|
null
clientStats
:
()
=>
webpack
.
Stats
|
null
serverStats
:
()
=>
webpack
.
Stats
|
null
serverStats
:
()
=>
webpack
.
Stats
|
null
edgeServerStats
:
()
=>
webpack
.
Stats
|
null
edgeServerStats
:
()
=>
webpack
.
Stats
|
null
...
...
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