Files
aragrp/middleware.ts
ar.badieiandCursor c2376b3b9e
Build & Push Docker Image / build (push) Has been cancelled
feat: redesign landing page with brand system and section blocks
Refresh the homepage around new hero/services/roadmap sections, shared design tokens, and updated brand assets.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-23 17:00:55 +03:30

26 lines
625 B
TypeScript

import { NextResponse } from "next/server";
import type { NextRequest } from "next/server";
/**
* Experimental site: only `/` exists. Send any other page request home
* so users never see a 404 screen.
*/
export function middleware(request: NextRequest) {
const { pathname } = request.nextUrl;
if (
pathname === "/" ||
pathname.startsWith("/_next") ||
pathname.startsWith("/api") ||
pathname.includes(".")
) {
return NextResponse.next();
}
return NextResponse.redirect(new URL("/", request.url));
}
export const config = {
matcher: ["/((?!_next/static|_next/image|favicon.ico).*)"],
};