From 39e2caf39a35aa2efa7b52be33bf128d61047a39 Mon Sep 17 00:00:00 2001 From: Bob Burningham Date: Sat, 7 Oct 2023 13:14:06 -0700 Subject: [PATCH] added middleware for clerks --- middleware.ts | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 middleware.ts diff --git a/middleware.ts b/middleware.ts new file mode 100644 index 0000000..d61b3eb --- /dev/null +++ b/middleware.ts @@ -0,0 +1,11 @@ +import { authMiddleware } from "@clerk/nextjs"; + +// This example protects all routes including api/trpc routes +// Please edit this to allow other routes to be public as needed. +// See https://clerk.com/docs/references/nextjs/auth-middleware for more information about configuring your middleware +export default authMiddleware({}); + +export const config = { + matcher: ['/((?!.+\\.[\\w]+$|_next).*)', '/', '/(api|trpc)(.*)'], +}; + \ No newline at end of file