import {
convexAuthNextjsMiddleware,
isAuthenticatedNextjs
} from "@convex-dev/auth/nextjs/server";
import { NextResponse } from "next/server";
// export default convexAuthNextjsMiddleware();
export default convexAuthNextjsMiddleware((request) => {
console.log("### middleware", request.url);
console.log("### isAuthenticatedNextjs", isAuthenticatedNextjs());
return NextResponse.next();
});
export const config = {
// The following matcher runs middleware on all routes
// except static assets.
matcher: ["/((?!.*\\..*|_next).*)", "/", "/(api|trpc)(.*)"],
};
import {
convexAuthNextjsMiddleware,
isAuthenticatedNextjs
} from "@convex-dev/auth/nextjs/server";
import { NextResponse } from "next/server";
// export default convexAuthNextjsMiddleware();
export default convexAuthNextjsMiddleware((request) => {
console.log("### middleware", request.url);
console.log("### isAuthenticatedNextjs", isAuthenticatedNextjs());
return NextResponse.next();
});
export const config = {
// The following matcher runs middleware on all routes
// except static assets.
matcher: ["/((?!.*\\..*|_next).*)", "/", "/(api|trpc)(.*)"],
};