Open Madhannmady07 opened 5 months ago
you can try installing this in the terminal: npm install @clerk/nextjs@beta
can u provide me your middleware.ts file , because in my file , it says authMiddleware is deprecated , how to resolve this properly?
As @PhungHoang1909 suggested, installing the clerk's beta version solved the problem. npm install @clerk/nextjs@beta
You can use clerkMiddleware()
instead of authMiddleware()
createRouteMatcher also works in the beta version of clerk.
As @PhungHoang1909 suggested, installing the clerk's beta version solved the problem.
npm install @clerk/nextjs@beta
You can useclerkMiddleware()
instead ofauthMiddleware()
createRouteMatcher also works in the beta version of clerk.
Its Out dated just. Use middleware.js from my repo and please give it a star 🌟
Thanks @PhungHoang1909 for this suggestion- installing the clerk's beta version really solved the problem. npm install @clerk/nextjs@beta You can use clerkMiddleware() instead of authMiddleware() createRouteMatcher also works in the beta version of clerk. till now i am not getting problems it really works .
Everything worked fine untill the Clerk Part , due to the change in the version release , I couldn't able to continue the project as same as before , to be precise , i was getting this error ....
Attempted import error: 'createRouteMatcher' is not exported from '@clerk/nextjs/server' (imported as 'createRouteMatcher').
./middleware.ts Attempted import error: 'clerkMiddleware' is not exported from '@clerk/nextjs/server' (imported as 'clerkMiddleware').
it's showing it has no such modules to export.
, can someone tell me how to install "Clerk Version 5" ? or how to solve this error , bcuz in the video he was using a different way (i mean diff middleware.ts file ) and now it is showing authMiddleware ... this stresses me up , someone help me