How can I implement authentication for a React SPA?
If I have a react SPA, how can I integrate it with with BetterAuth + Express? I want to do for auth for a React SPA, without any frameworks like NextJS, Remix, etc.
You can mount the server on Express and use the client SDK on the React side, and it should work. But, keep in mind that since Better Auth relies on cookies, your frontend and backend need to be deployed using a subdomain setup, otherwise, cross-domain cookies won't work properly.