Download next.js/test/e2e/app-dir/app-rendering/app/static-only/layout.js from Devendra174/react-code-dataset: direct link, hf CLI and curl.
- Browser
- Download file 287 Bytes
-
https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/next.js/test/e2e/app-dir/app-rendering/app/static-only/layout.js
- Command line
-
hf download hf://datasets/Devendra174/react-code-dataset/next.js/test/e2e/app-dir/app-rendering/app/static-only/layout.js
-
curl -L -o layout.js https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/next.js/test/e2e/app-dir/app-rendering/app/static-only/layout.js
287 Bytes
| import { use } from 'react' | |
| async function getData() { | |
| return { | |
| message: 'hello from layout', | |
| } | |
| } | |
| export default function GspLayout(props) { | |
| const data = use(getData()) | |
| return ( | |
| <> | |
| <h1 id="layout-message">{data.message}</h1> | |
| {props.children} | |
| </> | |
| ) | |
| } | |