Skip to content

feat: add OAuth 2.0 login/Signup with Google and GitHub#151

Open
vd77-1 wants to merge 3 commits into
ThePlator:mainfrom
vd77-1:feat/oauth2
Open

feat: add OAuth 2.0 login/Signup with Google and GitHub#151
vd77-1 wants to merge 3 commits into
ThePlator:mainfrom
vd77-1:feat/oauth2

Conversation

@vd77-1

@vd77-1 vd77-1 commented May 26, 2026

Copy link
Copy Markdown
Contributor
  • Add passport.js with Google and GitHub strategies
  • Add OAuth callback routes (/api/v1/auth/google, /api/v1/auth/github)
  • Update User schema with googleId, githubId fields, make password optional
  • Add OAuthButtons component with theme styling
  • Add oauth-callback page to handle token after redirect
  • Wire up passport.initialize() in server.js"

sign up page
Screenshot (323)

Log in page
Screenshot (324)

@vercel

vercel Bot commented May 26, 2026

Copy link
Copy Markdown
Contributor

@vd77-1 is attempting to deploy a commit to the Sameer's projects Team on Vercel.

A member of the Team first needs to authorize it.

@ThePlator

Copy link
Copy Markdown
Owner

Hi @vd77-1! This is a fantastic implementation of OAuth 2.0. Adding Google and GitHub login will significantly improve our onboarding flow.

However, there is a major technical blocker: we just merged PR #122 (Secure Dual-Token Auth), which moved our authentication to an httpOnly cookie system and removed the use of localStorage for tokens.

Please rebase your branch on the latest 'main' and update your OAuth flow:

  1. Instead of redirecting to the frontend with a ?token= param, the backend callback should use the setAuthCookies utility to set the refreshToken and refreshTokenId.
  2. The frontend oauth-callback page should then simply call checkAuth() without manually touching localStorage.

Once the OAuth flow is integrated with our new secure token architecture, I'll be happy to merge this milestone!

@ThePlator ThePlator self-requested a review May 27, 2026 11:13
@vd77-1

vd77-1 commented May 27, 2026

Copy link
Copy Markdown
Contributor Author

Ok ,I will update you soon with that

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants