From 8b4a6cce26c3309d25640e9a35734b8fb70a3786 Mon Sep 17 00:00:00 2001 From: Tim Neutkens Date: Wed, 13 Sep 2023 13:25:28 +0200 Subject: [PATCH] Use NextJsHotReloaderInterface in router-server --- packages/next/src/server/lib/router-server.ts | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/packages/next/src/server/lib/router-server.ts b/packages/next/src/server/lib/router-server.ts index f95bbdf6dbbb4..7e24bb9bd5ce0 100644 --- a/packages/next/src/server/lib/router-server.ts +++ b/packages/next/src/server/lib/router-server.ts @@ -38,6 +38,7 @@ import { PHASE_DEVELOPMENT_SERVER, PERMANENT_REDIRECT_STATUS, } from '../../shared/lib/constants' +import type { NextJsHotReloaderInterface } from '../dev/hot-reloader-types' const debug = setupDebug('next:router-server:main') @@ -134,11 +135,7 @@ export async function initialize(opts: { ;(global as any)._nextDevHandlers = { async ensurePage( dir: string, - match: Parameters< - InstanceType< - typeof import('../dev/hot-reloader-webpack').default - >['ensurePage'] - >[0] + match: Parameters[0] ) { const curDevInstance = devInstances[dir] // TODO: remove after ensure is pulled out of server