Download next.js/test/development/app-dir/dev-fetch-hmr/app/page.tsx from Devendra174/react-code-dataset: direct link, hf CLI and curl.
- Browser
- Download file 414 Bytes
-
https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/next.js/test/development/app-dir/dev-fetch-hmr/app/page.tsx
- Command line
-
hf download hf://datasets/Devendra174/react-code-dataset/next.js/test/development/app-dir/dev-fetch-hmr/app/page.tsx
-
curl -L -o page.tsx https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/next.js/test/development/app-dir/dev-fetch-hmr/app/page.tsx
414 Bytes
| export default async function Page() { | |
| const secret = (await fetch('http://fake.url/secret').then((res) => | |
| res.text() | |
| )) as any | |
| const magicNumber = (await fetch('http://fake.url/magic-number').then((res) => | |
| res.text() | |
| )) as any | |
| return ( | |
| <> | |
| <div id="update">touch to trigger HMR</div> | |
| <div id="secret">{secret}</div> | |
| <div id="magic-number">{magicNumber}</div> | |
| </> | |
| ) | |
| } | |