diff --git a/packages/next/src/build/webpack-config.ts b/packages/next/src/build/webpack-config.ts index 7123a3c94d834..0b5973e55e972 100644 --- a/packages/next/src/build/webpack-config.ts +++ b/packages/next/src/build/webpack-config.ts @@ -87,7 +87,7 @@ const NEXT_PROJECT_ROOT_DIST_CLIENT = path.join( ) const isWebpackServerLayer = (layer: WebpackLayerName | null) => - Boolean(layer && WEBPACK_LAYERS.GROUP.server.includes(layer)) + Boolean(layer && WEBPACK_LAYERS.GROUP.server.includes(layer as any)) if (parseInt(React.version) < 18) { throw new Error('Next.js requires react >= 18.2.0 to be installed.') diff --git a/packages/next/src/lib/metadata/metadata.tsx b/packages/next/src/lib/metadata/metadata.tsx index e32ed342dfae3..fe86008973641 100644 --- a/packages/next/src/lib/metadata/metadata.tsx +++ b/packages/next/src/lib/metadata/metadata.tsx @@ -129,6 +129,5 @@ export function createMetadataComponents({ return null } - // @ts-expect-error async server components return [MetadataTree, MetadataOutlet] } diff --git a/packages/next/src/server/app-render/app-render.tsx b/packages/next/src/server/app-render/app-render.tsx index 11c094e6691de..231333a711a25 100644 --- a/packages/next/src/server/app-render/app-render.tsx +++ b/packages/next/src/server/app-render/app-render.tsx @@ -1105,7 +1105,7 @@ export async function renderToHTMLOrFlight( isPrefetch && !Boolean(components.loading) ? null : // Create component tree using the slice of the loaderTree - // @ts-expect-error TODO-APP: fix async component type + React.createElement(async () => { const { Component } = await createComponentTree( // This ensures flightRouterPath is valid and filters down the tree