docs: fix index.html.md causing 404 (#12241)
* docs: fix index.html.md causing 404 * update next.js * test * test * test * test * fix revalidate * test * test * test * test * test * test * test * test * clean up
This commit is contained in:
@@ -18,7 +18,7 @@
|
||||
"@mdx-js/react": "^3.1.0",
|
||||
"@medusajs/icons": "2.6.0",
|
||||
"@medusajs/ui": "4.0.6",
|
||||
"@next/mdx": "15.0.4",
|
||||
"@next/mdx": "15.3.1",
|
||||
"@react-hook/resize-observer": "^2.0.2",
|
||||
"@readme/openapi-parser": "^2.5.0",
|
||||
"algoliasearch": "4",
|
||||
@@ -29,7 +29,7 @@
|
||||
"jsdom": "^22.1.0",
|
||||
"json-schema": "^0.4.0",
|
||||
"json-stringify-pretty-compact": "^4.0.0",
|
||||
"next": "15.0.4",
|
||||
"next": "15.3.1",
|
||||
"next-mdx-remote": "5.0.0",
|
||||
"openapi-sampler": "^1.3.1",
|
||||
"pluralize": "^8.0.0",
|
||||
@@ -51,7 +51,7 @@
|
||||
"yaml": "^2.3.1"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@next/bundle-analyzer": "15.0.4",
|
||||
"@next/bundle-analyzer": "15.3.1",
|
||||
"@types/jsdom": "^21.1.1",
|
||||
"@types/mapbox__rehype-prism": "^0.8.0",
|
||||
"@types/mdx": "^2.0.13",
|
||||
|
||||
@@ -169,6 +169,9 @@ const nextConfig = {
|
||||
}
|
||||
},
|
||||
redirects,
|
||||
outputFileTracingIncludes: {
|
||||
"/md\\-content/\\[\\.\\.\\.slug\\]": ["./app/**/*.mdx"],
|
||||
},
|
||||
outputFileTracingExcludes: {
|
||||
"*": ["node_modules/@medusajs/icons"],
|
||||
},
|
||||
|
||||
@@ -17,11 +17,11 @@
|
||||
"@mdx-js/loader": "^3.1.0",
|
||||
"@mdx-js/react": "^3.1.0",
|
||||
"@medusajs/icons": "~2.5.1",
|
||||
"@next/mdx": "15.0.4",
|
||||
"@next/mdx": "15.3.1",
|
||||
"clsx": "^2.1.0",
|
||||
"docs-ui": "*",
|
||||
"docs-utils": "*",
|
||||
"next": "15.0.4",
|
||||
"next": "15.3.1",
|
||||
"react": "rc",
|
||||
"react-dom": "rc",
|
||||
"rehype-mdx-code-props": "^2.0.0",
|
||||
|
||||
@@ -31,7 +31,7 @@ export async function GET(req: NextRequest, { params }: Params) {
|
||||
return notFound()
|
||||
}
|
||||
|
||||
const filePath = path.join(path.resolve("..", "..", ".."), filePathFromMap)
|
||||
const filePath = path.join(process.cwd(), "..", "..", "..", filePathFromMap)
|
||||
|
||||
if (!existsSync(filePath)) {
|
||||
return notFound()
|
||||
|
||||
@@ -58,7 +58,7 @@ const nextConfig = {
|
||||
// Configure `pageExtensions` to include MDX files
|
||||
pageExtensions: ["js", "jsx", "mdx", "ts", "tsx"],
|
||||
|
||||
transpilePackages: ["docs-ui"],
|
||||
transpilePackages: ["docs-ui", "next-mdx-remote"],
|
||||
|
||||
basePath: process.env.NEXT_PUBLIC_BASE_PATH || "/resources",
|
||||
async redirects() {
|
||||
@@ -178,6 +178,10 @@ const nextConfig = {
|
||||
outputFileTracingExcludes: {
|
||||
"*": ["node_modules/@medusajs/icons"],
|
||||
},
|
||||
outputFileTracingIncludes: {
|
||||
"/md\\-content/\\[\\[\\.\\.\\.slug\\]\\]": ["./app/**/*.mdx"],
|
||||
"/md\\-content/references/**": ["./references/**/*.mdx"],
|
||||
},
|
||||
experimental: {
|
||||
optimizePackageImports: ["@medusajs/icons", "@medusajs/ui", "elkjs"],
|
||||
},
|
||||
|
||||
@@ -17,10 +17,10 @@
|
||||
"@mdx-js/loader": "^3.1.0",
|
||||
"@mdx-js/react": "^3.1.0",
|
||||
"@medusajs/icons": "~2.5.1",
|
||||
"@next/mdx": "15.0.4",
|
||||
"@next/mdx": "15.3.1",
|
||||
"clsx": "^2.1.0",
|
||||
"docs-ui": "*",
|
||||
"next": "15.0.4",
|
||||
"next": "15.3.1",
|
||||
"react": "rc",
|
||||
"react-dom": "rc",
|
||||
"rehype-mdx-code-props": "^2.0.0",
|
||||
|
||||
@@ -4,6 +4,13 @@ const { withContentlayer } = require("next-contentlayer")
|
||||
const nextConfig = {
|
||||
basePath: process.env.NEXT_PUBLIC_BASE_PATH || "/ui",
|
||||
reactStrictMode: true,
|
||||
outputFileTracingIncludes: {
|
||||
"/md\\-content/\\[\\[\\.\\.\\.slug\\]\\]": [
|
||||
"./src/content/docs/**/*.mdx",
|
||||
"./specs/**/*",
|
||||
"./examples/**/*"
|
||||
],
|
||||
},
|
||||
}
|
||||
|
||||
module.exports = withContentlayer(nextConfig)
|
||||
|
||||
@@ -27,7 +27,7 @@
|
||||
"docs-ui": "*",
|
||||
"docs-utils": "*",
|
||||
"mdast-util-toc": "^7.0.0",
|
||||
"next": "15.0.4",
|
||||
"next": "15.3.1",
|
||||
"next-contentlayer": "^0.3.4",
|
||||
"next-themes": "^0.2.1",
|
||||
"postcss": "8.4.27",
|
||||
|
||||
@@ -105,6 +105,9 @@ const nextConfig = {
|
||||
|
||||
transpilePackages: ["docs-ui"],
|
||||
basePath: process.env.NEXT_PUBLIC_BASE_PATH || "/user-guide",
|
||||
outputFileTracingIncludes: {
|
||||
"/md\\-content/\\[\\[\\.\\.\\.slug\\]\\]": ["./app/**/*.mdx"],
|
||||
},
|
||||
outputFileTracingExcludes: {
|
||||
"*": ["node_modules/@medusajs/icons"],
|
||||
},
|
||||
|
||||
@@ -33,7 +33,7 @@
|
||||
"@babel/eslint-parser": "^7.25.9",
|
||||
"@eslint/js": "9.13.0",
|
||||
"@types/eslint__js": "8.42.3",
|
||||
"eslint-config-next": "15.0.4",
|
||||
"eslint-config-next": "15.3.1",
|
||||
"eslint-config-prettier": "9.1.0",
|
||||
"eslint-config-turbo": "2.2.3",
|
||||
"eslint-plugin-markdown": "5.1.0",
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
"clsx": "^2.0.0",
|
||||
"cpy-cli": "^5.0.0",
|
||||
"eslint": "^9.13.0",
|
||||
"next": "15.0.4",
|
||||
"next": "15.3.1",
|
||||
"rimraf": "^5.0.1",
|
||||
"tailwind": "*",
|
||||
"tailwindcss": "^3.3.3",
|
||||
@@ -59,7 +59,7 @@
|
||||
"@emotion/is-prop-valid": "^1.3.1",
|
||||
"@medusajs/icons": "2.6.0",
|
||||
"@medusajs/ui": "4.0.6",
|
||||
"@next/third-parties": "15.0.4",
|
||||
"@next/third-parties": "15.3.1",
|
||||
"@octokit/request": "^8.1.1",
|
||||
"@react-hook/resize-observer": "^1.2.6",
|
||||
"@segment/analytics-next": "^1.75.0",
|
||||
|
||||
1399
www/yarn.lock
1399
www/yarn.lock
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user