using the useSession hook with react/next
Code for context:
Component
I get this type error in VSCode
Not sure if this is relevant but if I run it anways i get a 404 on
Component
I get this type error in VSCode
Not sure if this is relevant but if I run it anways i get a 404 on
http://localhost:3001/api/auth/use-session in the network tab, I think its supposed to be calling get-session but i'm not sure why the hook from the library is doing this.Solution
Okay I figured it out, useSession only works if your are using better auth and next as full stack not if you have your better auth backend on express and just using next as a front end.