diff --git a/middleware.ts b/middleware.ts new file mode 100644 index 0000000..92e57ec --- /dev/null +++ b/middleware.ts @@ -0,0 +1,12 @@ +export const config = { + matcher: [ + /* + * Match all request paths except for the ones starting with: + * - api (API routes) + * - _next/static (static files) + * - _next/image (image optimization files) + * - favicon.ico (favicon file) + */ + "/((?!api|_next/static|_next/image|favicon.ico).*)", + ], +}; diff --git a/src/app/layout.tsx b/src/app/layout.tsx index 647ed68..654efae 100644 --- a/src/app/layout.tsx +++ b/src/app/layout.tsx @@ -2,7 +2,8 @@ import type { Metadata } from "next"; import { Inter } from "next/font/google"; import "./globals.css"; import { ThemeProvider } from "@/providers/theme-provider"; -import { Toaster } from "@/components/ui/sonner" +import { Toaster } from "@/components/ui/sonner"; +export const runtime = "edge"; // 'nodejs' (default) | 'edge' const inter = Inter({ subsets: ["latin"] }); @@ -12,11 +13,11 @@ export const metadata: Metadata = { }; export const viewport = { - width: 'device-width', + width: "device-width", initialScale: 1, maximumScale: 1, userScalable: 1, -} +}; export default function RootLayout({ children, @@ -28,7 +29,7 @@ export default function RootLayout({ {children} - +