diff --git a/docs/next-js/next.config.ts b/docs/next-js/next.config.ts index 28295aa..6e99111 100644 --- a/docs/next-js/next.config.ts +++ b/docs/next-js/next.config.ts @@ -2,6 +2,7 @@ import type { NextConfig } from "next"; const isProd = process.env.NODE_ENV === 'production'; const basePath = isProd ? (process.env.BASE_PATH || '') : ''; +const assetPrefix = isProd ? (basePath ? `${basePath.replace(/\/$/, '')}/` : './') : ''; console.log("BASE_PATH", basePath) @@ -10,7 +11,7 @@ const nextConfig: NextConfig = { output: 'export' as const, basePath: basePath, trailingSlash: true, - // assetPrefix: assetPrefix, + assetPrefix: assetPrefix, images: { unoptimized: true, },