Skip to main content
AI Assist is now on Stack Overflow. Start a chat to get instant answers from across the network. Sign up to save and share your chats.
added 230 characters in body
Source Link

I have been trying to set up Clerk for my NextJS project but I keep having Errors. I am using NextJS 13 with the app directory in a src folder, Clerk middleware is located in src also. Firefox console error "(Reason: CORS request did not succeed). Status code: (null).", "Uncaught (in promise) Error: Clerk: Failed to load Clerk"

I also can't get the user info from the auth()/currentUser(), it always returns undefined even if I sign-in correctly.

I haven't been able to find many posts that talked about this issue, but some mentioned: -,,Enable URL-based session syncing,, in settings of the project on the Clerk website, but that is turned off by default. -One recommendation was to disable HTTPS everywhere but i don't even have it.

EDIT: changed my browser to Edge and the CORS problem went away. I can sign in correctly and stuff, but I still have no access to currentUser() function from Clerk, I can be logged in and still receive undefined.

I have been trying to set up Clerk for my NextJS project but I keep having Errors. I am using NextJS 13 with the app directory in a src folder, Clerk middleware is located in src also. Firefox console error "(Reason: CORS request did not succeed). Status code: (null).", "Uncaught (in promise) Error: Clerk: Failed to load Clerk"

I also can't get the user info from the auth(), it always returns undefined even if I sign-in correctly.

I haven't been able to find many posts that talked about this issue, but some mentioned: -,,Enable URL-based session syncing,, in settings of the project on the Clerk website, but that is turned off by default. -One recommendation was to disable HTTPS everywhere but i don't even have it.

I have been trying to set up Clerk for my NextJS project but I keep having Errors. I am using NextJS 13 with the app directory in a src folder, Clerk middleware is located in src also. Firefox console error "(Reason: CORS request did not succeed). Status code: (null).", "Uncaught (in promise) Error: Clerk: Failed to load Clerk"

I also can't get the user info from the auth()/currentUser(), it always returns undefined even if I sign-in correctly.

I haven't been able to find many posts that talked about this issue, but some mentioned: -,,Enable URL-based session syncing,, in settings of the project on the Clerk website, but that is turned off by default. -One recommendation was to disable HTTPS everywhere but i don't even have it.

EDIT: changed my browser to Edge and the CORS problem went away. I can sign in correctly and stuff, but I still have no access to currentUser() function from Clerk, I can be logged in and still receive undefined.

Source Link

NextJs with Clerk Auth. Uncaught (in promise) Error: Clerk: Failed to load Clerk

I have been trying to set up Clerk for my NextJS project but I keep having Errors. I am using NextJS 13 with the app directory in a src folder, Clerk middleware is located in src also. Firefox console error "(Reason: CORS request did not succeed). Status code: (null).", "Uncaught (in promise) Error: Clerk: Failed to load Clerk"

I also can't get the user info from the auth(), it always returns undefined even if I sign-in correctly.

I haven't been able to find many posts that talked about this issue, but some mentioned: -,,Enable URL-based session syncing,, in settings of the project on the Clerk website, but that is turned off by default. -One recommendation was to disable HTTPS everywhere but i don't even have it.