Download next.js/test/e2e/app-dir/app-compilation/app/page-with-loading/page.js from Devendra174/react-code-dataset: direct link, hf CLI and curl.
- Browser
- Download file 337 Bytes
-
https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/next.js/test/e2e/app-dir/app-compilation/app/page-with-loading/page.js
- Command line
-
hf download hf://datasets/Devendra174/react-code-dataset/next.js/test/e2e/app-dir/app-compilation/app/page-with-loading/page.js
-
curl -L -o page.js https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/next.js/test/e2e/app-dir/app-compilation/app/page-with-loading/page.js
337 Bytes
| import { use } from 'react' | |
| async function getData() { | |
| await new Promise((resolve) => setTimeout(resolve, 1000)) | |
| return { | |
| message: 'hello from slow page', | |
| } | |
| } | |
| export default function SlowPage() { | |
| const data = use(getData()) | |
| return <h1 id="slow-page-message">{data.message}</h1> | |
| } | |
| export const dynamic = 'force-dynamic' | |