Download next.js/test/development/app-dir/segment-explorer/app/search/page.tsx from Devendra174/react-code-dataset: direct link, hf CLI and curl.
- Browser
- Download file 506 Bytes
-
https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/next.js/test/development/app-dir/segment-explorer/app/search/page.tsx
- Command line
-
hf download hf://datasets/Devendra174/react-code-dataset/next.js/test/development/app-dir/segment-explorer/app/search/page.tsx
-
curl -L -o page.tsx https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/next.js/test/development/app-dir/segment-explorer/app/search/page.tsx
506 Bytes
| import { Search } from './search' | |
| type AnySearchParams = { [key: string]: string | Array<string> | undefined } | |
| export default async function Page({ | |
| searchParams, | |
| }: { | |
| searchParams: Promise<AnySearchParams> | |
| }) { | |
| const search = await searchParams | |
| if (Object.keys(search).length > 0) { | |
| await new Promise((resolve) => setTimeout(resolve, 30 * 1000)) | |
| } | |
| return ( | |
| <main id="page-content"> | |
| <Search /> | |
| <p id="search-value">Search Value: {search.q ?? 'None'}</p> | |
| </main> | |
| ) | |
| } | |