Download next.js/examples/cms-buttercms/next.config.js from Devendra174/react-code-dataset: direct link, hf CLI and curl.
- Browser
- Download file 912 Bytes
-
https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/next.js/examples/cms-buttercms/next.config.js
- Command line
-
hf download hf://datasets/Devendra174/react-code-dataset/next.js/examples/cms-buttercms/next.config.js
-
curl -L -o next.config.js https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/next.js/examples/cms-buttercms/next.config.js
912 Bytes
| /** @type {import('next').NextConfig} */ | |
| module.exports = { | |
| reactStrictMode: true, | |
| async rewrites() { | |
| return [ | |
| { | |
| source: "/", | |
| destination: "/landing-page/landing-page-with-components", | |
| }, | |
| ]; | |
| }, | |
| redirects() { | |
| const sourcesRequiringAuthToken = [ | |
| "/", | |
| "/landing-page/:slug*", | |
| "/blog/:path*", | |
| ]; | |
| return process.env.NEXT_PUBLIC_BUTTER_CMS_API_KEY | |
| ? [ | |
| { | |
| source: "/missing-token", | |
| destination: "/", | |
| permanent: false, | |
| }, | |
| ] | |
| : sourcesRequiringAuthToken.map((source) => ({ | |
| source: source, | |
| destination: "/missing-token", | |
| permanent: false, | |
| })); | |
| }, | |
| images: { | |
| remotePatterns: [ | |
| { | |
| protocol: "https", | |
| hostname: "cdn.buttercms.com", | |
| port: "", | |
| pathname: "/my-account/**", | |
| }, | |
| ], | |
| }, | |
| }; | |