The modern link attribution platform. Loved by world-class engineering teams at Twilio, Zillow, Jobber, Vercel, Raycast, and more.
TypeScript clickhousemysqlnextjsopen-sourceplanetscaleprismatailwindcsstinybirdtypescriptupstashvercel
changed routes
Steven Tey0bf2973c5a13
diff --git a/lib/constants/index.ts b/lib/constants/index.tsindex 8833ef36c8..9803656420 100644--- a/lib/constants/index.ts+++ b/lib/constants/index.ts@@ -45,6 +45,7 @@ export const RESERVED_KEYS = new Set(["pricing","about","placeholder",+ "metatags","blog","careers","docs",diff --git a/lib/middleware/api.ts b/lib/middleware/api.tsindex 01cd5b7805..43365d4929 100644--- a/lib/middleware/api.ts+++ b/lib/middleware/api.ts@@ -6,7 +6,7 @@ export default async function ApiMiddleware(req: NextRequest) {if (path.startsWith("/metatags")) {const url = req.nextUrl.searchParams.get("url");if (!url) {- return NextResponse.rewrite(new URL("/docs/metatags", req.url));+ return NextResponse.rewrite(new URL("/metatags", req.url));}return NextResponse.rewrite(new URL(`/api/edge/metatags?url=${url}`, req.url),diff --git a/pages/docs/metatags.tsx b/pages/metatags.tsxsimilarity index 99%rename from pages/docs/metatags.tsxrename to pages/metatags.tsxindex 8f2bf0f2c2..6fb3c6fc7a 100644--- a/pages/docs/metatags.tsx+++ b/pages/metatags.tsx@@ -10,7 +10,6 @@ export default function Metatags({ tweets }: { tweets: any }) {const [url, setUrl] = useState("");return (<HomeLayout- domain="api.dub.sh"meta={<Metatitle="Metatags API - The Free API to Get Meta Tags from a URL"