Library recommendation for Authentication on React?

On React Ive only worked with Cognito but since Im not using AWS I dont know what else. Ive built once an app doing from scratch but on Next.js. Im also using monorepo (dont know if it gives any advantages for share code with server so)
14 Replies
djcmurphy
djcmurphy14mo ago
If you don't want to do your own then Clerk is the new Auth kid in town. Clerk.dev If you want to roll your own then iron-session github will get you going. It uses a stateless cookie.
kevinka
kevinka14mo ago
iron session github isnt for next.js? (just had a quick look)
djcmurphy
djcmurphy14mo ago
I use it in next with app directory and even trpc
djcmurphy
djcmurphy14mo ago
GitHub
GitHub - vvo/iron-session: 🛠 Next.js stateless session utility usin...
🛠 Next.js stateless session utility using signed and encrypted cookies to store data. Also works with Express, and Node.js HTTP servers - GitHub - vvo/iron-session: 🛠 Next.js stateless session util...
djcmurphy
djcmurphy14mo ago
a lot of work if you just want a client login though emails and such for passwords etc next-auth is another option
djcmurphy
djcmurphy14mo ago
NextAuth.js
Authentication for Next.js
djcmurphy
djcmurphy14mo ago
I use iron session because it is an app for businesses where HR makes accounts. No need for social logins. The other options come with social logins but you give up controls of the user DB nextauth is oss and you control DB, clerk is paid for with other features(emails, pasword reset,all the stuff you would expect), iron session is raw cookie storage on server
Neto
Neto14mo ago
kevinka
kevinka14mo ago
@MonobrainChris @nyx (Rustular DevRel) but isnt all of them for next? Im not using Next!
Neto
Neto14mo ago
What are you using?
Mendy
Mendy14mo ago
No, expect for iron session
Sybatron
Sybatron14mo ago
They are moving nextauth towards this https://authjs.dev
Auth.js
Authentication for the Web.
Sybatron
Sybatron14mo ago
its still experimental though
Sybatron
Sybatron14mo ago
and lucia has quite few options for using it