In appdir, what should the type of children be?

Current getting an error saying that children is implicitly of type any. What is the recommended type to use for it? Thanks!
// app/layout.tsx
export default function RootLayout({ children }) {
return (
<html lang="en">
<body>{children}</body>
</html>
);
}
// app/layout.tsx
export default function RootLayout({ children }) {
return (
<html lang="en">
<body>{children}</body>
</html>
);
}
binding element 'children' implicitly has an 'any' type.
Solution:
Current getting an error saying that children is implicitly of type any. What is the recommended type to use for it? Thanks! ```tsx // app/layout.tsx export default function RootLayout({ children }) {...
Jump to solution
4 Replies
cje
cje3y ago
ReactNode same as before
Liam
LiamOP3y ago
Thanks!
Finn
Finn3y ago
you can do props with children or smth iirc
Revaycolizer
Revaycolizer3y ago
meaning in any of your component ??

Did you find this page helpful?