Spaces:
Build error
Build error
// 位於 app/layout.tsx | |
import type { Metadata } from "next"; | |
// 修正:直接只匯入 ReactNode 這個「類型」,而不是整個 React 物件 | |
import type { ReactNode } from 'react'; | |
export const metadata: Metadata = { | |
title: "MIDI Player Lite", | |
description: "A lightweight MIDI player for Hugging Face Spaces.", | |
}; | |
// 修正:直接使用 ReactNode,不再需要寫 React.ReactNode | |
export default function RootLayout({ children }: { children: ReactNode }) { | |
return ( | |
<html lang="en"> | |
<body>{children}</body> | |
</html> | |
); | |
} |