docs: fix rewrites for markdown and plain content (#13916)
This commit is contained in:
@@ -122,23 +122,12 @@ const nextConfig = {
|
||||
destination: "/md-content/:path*",
|
||||
},
|
||||
{
|
||||
source: "/:path*",
|
||||
source: "/:path((?!resources|api|ui|user-guide|cloud).*)*",
|
||||
has: [
|
||||
{
|
||||
type: "header",
|
||||
key: "Accept",
|
||||
value: "text/markdown",
|
||||
},
|
||||
],
|
||||
destination: "/md-content/:path*",
|
||||
},
|
||||
{
|
||||
source: "/:path*",
|
||||
has: [
|
||||
{
|
||||
type: "header",
|
||||
key: "Accept",
|
||||
value: "text/plain",
|
||||
value: ".*(text/markdown|text/plain).*",
|
||||
},
|
||||
],
|
||||
destination: "/md-content/:path*",
|
||||
|
||||
@@ -164,23 +164,12 @@ const nextConfig = {
|
||||
has: [
|
||||
{
|
||||
type: "header",
|
||||
key: "accept",
|
||||
value: "text/markdown",
|
||||
key: "Accept",
|
||||
value: ".*(text/markdown|text/plain).*",
|
||||
},
|
||||
],
|
||||
destination: "/md-content/:path*",
|
||||
},
|
||||
{
|
||||
source: "/:path*",
|
||||
destination: "/md-content/:path*",
|
||||
has: [
|
||||
{
|
||||
type: "header",
|
||||
key: "accept",
|
||||
value: "text/plain",
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
}
|
||||
},
|
||||
|
||||
@@ -298,23 +298,12 @@ const nextConfig = {
|
||||
has: [
|
||||
{
|
||||
type: "header",
|
||||
key: "accept",
|
||||
value: "text/markdown",
|
||||
key: "Accept",
|
||||
value: ".*(text/markdown|text/plain).*",
|
||||
},
|
||||
],
|
||||
destination: "/md-content/:path*",
|
||||
},
|
||||
{
|
||||
source: "/:path*",
|
||||
destination: "/md-content/:path*",
|
||||
has: [
|
||||
{
|
||||
type: "header",
|
||||
key: "accept",
|
||||
value: "text/plain",
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
}
|
||||
},
|
||||
|
||||
@@ -153,23 +153,12 @@ const nextConfig = {
|
||||
has: [
|
||||
{
|
||||
type: "header",
|
||||
key: "accept",
|
||||
value: "text/markdown",
|
||||
key: "Accept",
|
||||
value: ".*(text/markdown|text/plain).*",
|
||||
},
|
||||
],
|
||||
destination: "/md-content/:path*",
|
||||
},
|
||||
{
|
||||
source: "/:path*",
|
||||
destination: "/md-content/:path*",
|
||||
has: [
|
||||
{
|
||||
type: "header",
|
||||
key: "accept",
|
||||
value: "text/plain",
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
}
|
||||
},
|
||||
|
||||
@@ -141,23 +141,12 @@ const nextConfig = {
|
||||
has: [
|
||||
{
|
||||
type: "header",
|
||||
key: "accept",
|
||||
value: "text/markdown",
|
||||
key: "Accept",
|
||||
value: ".*(text/markdown|text/plain).*",
|
||||
},
|
||||
],
|
||||
destination: "/md-content/:path*",
|
||||
},
|
||||
{
|
||||
source: "/:path*",
|
||||
destination: "/md-content/:path*",
|
||||
has: [
|
||||
{
|
||||
type: "header",
|
||||
key: "accept",
|
||||
value: "text/plain",
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
}
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user