Download next.js/packages/font/local/index.js from Devendra174/react-code-dataset: direct link, hf CLI and curl.
- Browser
- Download file 587 Bytes
-
https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/next.js/packages/font/local/index.js
- Command line
-
hf download hf://datasets/Devendra174/react-code-dataset/next.js/packages/font/local/index.js
-
curl -L -o index.js https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/next.js/packages/font/local/index.js
587 Bytes
| // Validate next version | |
| const semver = require('next/dist/compiled/semver') | |
| if (semver.lt(require('next/package.json').version, '13.0.0')) { | |
| throw new Error('`@next/font` is only available in Next.js 13 and newer.') | |
| } | |
| let message = '@next/font/local failed to run or is incorrectly configured.' | |
| if (process.env.NODE_ENV === 'development') { | |
| message += | |
| '\nIf you just installed `@next/font`, please try restarting `next dev` and resaving your file.' | |
| } | |
| message += `\n\nRead more: https://nextjs.org/docs/app/building-your-application/optimizing/fonts` | |
| throw new Error(message) | |