Files
computer/docs/next.config.mjs
2025-07-31 11:53:14 +01:00

49 lines
919 B
JavaScript

import { createMDX } from 'fumadocs-mdx/next';
const withMDX = createMDX();
/** @type {import('next').NextConfig} */
const config = {
reactStrictMode: true,
trailingSlash: false,
basePath: '/docs',
assetPrefix: '/docs',
async rewrites() {
return [
{
source: '/:path*.mdx',
destination: '/llms.mdx/:path*',
},
];
},
async redirects() {
return [
{
source: '/',
destination: '/docs',
basePath: false, // Important: this bypasses the basePath
permanent: false,
},
];
},
images: {
dangerouslyAllowSVG: true,
remotePatterns: [
{
protocol: 'https',
hostname: 'img.shields.io',
},
{
protocol: 'https',
hostname: 'starchart.cc',
},
{
protocol: 'https',
hostname: 'github.com',
},
],
},
};
export default withMDX(config);