Skip to content

Commit b46b1e1

Browse files
authored
Drop react-dev-overlay from production bundle (#68197)
1 parent eedbfa1 commit b46b1e1

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

packages/next/src/client/components/router-reducer/fetch-server-response.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@ import {
2929
import { callServer } from '../../app-call-server'
3030
import { PrefetchKind } from './router-reducer-types'
3131
import { hexHash } from '../../../shared/lib/hash'
32-
import { waitForWebpackRuntimeHotUpdate } from '../react-dev-overlay/app/hot-reloader-client'
3332

3433
export interface FetchServerResponseOptions {
3534
readonly flightRouterState: FlightRouterState
@@ -191,7 +190,7 @@ export async function fetchServerResponse(
191190
// In dev, the Webpack runtime is minimal for each page.
192191
// We need to ensure the Webpack runtime is updated before executing client-side JS of the new page.
193192
if (process.env.NODE_ENV !== 'production' && !process.env.TURBOPACK) {
194-
await waitForWebpackRuntimeHotUpdate()
193+
await require('../react-dev-overlay/app/hot-reloader-client').waitForWebpackRuntimeHotUpdate()
195194
}
196195

197196
// Handle the `fetch` readable stream that can be unwrapped by `React.use`.

0 commit comments

Comments
 (0)