Download src/app/[org]/[dataset]/page.tsx from DynamicIntelligence/dynamic_intelligence_sample_data: direct link, hf CLI and curl.
- Browser
- Download file 402 Bytes
-
https://huggingface.co/spaces/DynamicIntelligence/dynamic_intelligence_sample_data/resolve/005ac78c01eb4fecf8bee4654d91e402ea5f7f73/src/app/%5Borg%5D/%5Bdataset%5D/page.tsx
- Command line
-
hf download 'hf://spaces/DynamicIntelligence/dynamic_intelligence_sample_data@005ac78c01eb4fecf8bee4654d91e402ea5f7f73/src/app/[org]/[dataset]/page.tsx'
-
curl -L -o page.tsx https://huggingface.co/spaces/DynamicIntelligence/dynamic_intelligence_sample_data/resolve/005ac78c01eb4fecf8bee4654d91e402ea5f7f73/src/app/%5Borg%5D/%5Bdataset%5D/page.tsx
402 Bytes
| import { redirect } from "next/navigation"; | |
| export default async function DatasetRootPage({ | |
| params, | |
| }: { | |
| params: Promise<{ org: string; dataset: string }>; | |
| }) { | |
| const { org, dataset } = await params; | |
| const episodeN = process.env.EPISODES | |
| ?.split(/\s+/) | |
| .map((x) => parseInt(x.trim(), 10)) | |
| .filter((x) => !isNaN(x))[0] ?? 0; | |
| redirect(`/${org}/${dataset}/episode_${episodeN}`); | |
| } | |