Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve GoogleProvider type and better support social auth for SPA #1277

Merged
merged 7 commits into from
Aug 22, 2024

Conversation

LoicPoullain
Copy link
Member

@LoicPoullain LoicPoullain commented Aug 22, 2024

Issue

  • The type of the userInfo property returned by GoogleProvider.getUserInfo is of type any.
  • In social auth, Foal only allows to get the consent page through a redirection and not a 200 response. This is not handy when building a SPA.

Solution and steps

  • Add type to GoogleProvider.getUserInfo.
  • Add a new createHttpResponseWithConsentPageUrl to get the consent page URL through an HttpResponseOK. This response includes the security cookie.

Checklist

  • Add/update/check docs (code comments and docs/ folder).
  • Add/update/check tests.
  • Update/check the cli generators.

@LoicPoullain LoicPoullain mentioned this pull request Aug 22, 2024
8 tasks
@LoicPoullain LoicPoullain merged commit 57b97e3 into v4-5-0 Aug 22, 2024
2 checks passed
@LoicPoullain LoicPoullain deleted the social-auth-google branch August 22, 2024 11:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

1 participant