nestjs-restful-best-practice
nestjs-restful-best-practice copied to clipboard
authservice Google/Facebook
hello, can you show me how oauth google and facebook work? because the code is missing thank you very much
hi, a little help would be really great ;)
Here are the three steps you need to follow to resolve your issue:
- Implement Google auth using @nestjs/passport and passport-google-auth (other providers are very similar).
- Once redirected back to the app, issue a JWT token, so the app can manage the user’s session.
- Protect REST and GraphQL endpoints with a JWT strategy.
Here is a link that might help you : https://javascript.plainenglish.io/oauth2-in-nestjs-for-social-login-google-facebook-twitter-etc-8b405d570fd2