Commit 71d9958f authored by Tobias Koppers's avatar Tobias Koppers

Remove unnecessary interopDefault export from app-page template

interopDefault is imported for use as a free variable in the injected loader
tree code. With verbatimModuleSyntax enabled, TypeScript preserves value
imports as-is without needing an explicit export to prevent elision.
Co-Authored-By: 's avatarClaude <noreply@anthropic.com>
parent e4db9ab2
......@@ -9,9 +9,9 @@ import * as entryBase from '../../server/app-render/entry-base' with { 'turbopac
// interopDefault is used as a free variable in the INJECT:tree generated code
// (see crates/next-core/src/app_page_loader_tree.rs), so it must remain in
// this template's compiled output as a local binding named `interopDefault`.
// The export below prevents TypeScript from eliding the import.
// verbatimModuleSyntax ensures the import is preserved as-is.
// eslint-disable-next-line @typescript-eslint/no-unused-vars
import { interopDefault } from '../../server/app-render/interop-default' with { 'turbopack-transition': 'next-server-utility' }
export { interopDefault }
import { createHandler } from '../../server/app-render/app-page' with { 'turbopack-transition': 'next-server-utility' }
......
......@@ -59,13 +59,7 @@ if (process.env.NEXT_RUNTIME !== 'edge') {
* The AppPageModule is the type of the module exported by the bundled app page
* module.
*/
export type AppPageModule = Omit<
typeof import('../../../build/templates/app-page'),
// interopDefault is exported from the template for use by the injected loader
// tree code (see crates/next-core/src/app_page_loader_tree.rs), not for use
// via ComponentMod in server code.
'interopDefault'
>
export type AppPageModule = typeof import('../../../build/templates/app-page')
type AppPageUserlandModule = {
/**
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment