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

feat(clerk-expo): Deprecate useOAuth and introduce docs for useSSO #1908

Merged
merged 27 commits into from
Feb 4, 2025

Conversation

LauraBeatris
Copy link
Member

@LauraBeatris LauraBeatris commented Jan 16, 2025

Related: #1907

Explanation:

⚠️ Needs these redirects https://github.com/clerk/clerk/pull/941

A new React hook got added to @clerk/expo to handle all SSO strategies, such as SAML and social/custom OAuth

useOAuth got deprecated in favor of useSSO

This PR:

Resolves ORGS-460

  • Deprecates useOAuth guide
  • Introduces docs for useSSO
  • Introduces code snippets for both social OAuth and SAML

Checklist

  • I have clicked on "Files changed" and performed a thorough self-review
  • I have added the "deploy-preview" label and added the preview link(s) to this PR description
  • All existing checks pass

Copy link

Hey, here’s your docs preview: https://clerk.com/docs/pr/1908

@LauraBeatris LauraBeatris force-pushed the laura/orgs-471-update-docs-for-clerkexpo branch 3 times, most recently from 47515ed to a6bdd0a Compare January 16, 2025 01:54
@LauraBeatris LauraBeatris marked this pull request as ready for review January 16, 2025 01:55
@LauraBeatris LauraBeatris requested a review from a team as a code owner January 16, 2025 01:55
@LauraBeatris LauraBeatris force-pushed the laura/orgs-471-update-docs-for-clerkexpo branch 2 times, most recently from 47aba5d to ba0aeb1 Compare January 16, 2025 01:57

<Tabs items={["With OAuth", "With SAML"]}>
<Tab>
The following example demonstrates how to create a custom SSO sign-in flow for [Google accounts](/docs/authentication/social-connections/google).
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If this is a custom sign-in flow, do we still want to link to this page?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Which page? Do you mean /docs/authentication/social-connections/google?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes! Would it make sense?

@victoriaxyz
Copy link
Contributor

victoriaxyz commented Jan 16, 2025

Hey @LauraBeatris, here's my review.

Update: d13a572

Notes

@LauraBeatris
Copy link
Member Author

We should also update for: https://clerk.com/docs/custom-flows/oauth-connections

@LauraBeatris LauraBeatris force-pushed the laura/orgs-471-update-docs-for-clerkexpo branch from c4d0914 to f9621d8 Compare January 17, 2025 18:25
@alexisintech
Copy link
Member

alexisintech commented Jan 17, 2025

Hi! Just did a review, and a question:

  1. I'm not seeing parameters for the useSSO() hook?

Summary of my review:
manifest.json

  • Added useOAuth() back to the sidenav, and marked it as deprecated
    docs/references/expo/use-oauth.mdx
  • Updated the deprecation callout in the useOAuth() guide
    docs/references/expo/use-sso.mdx
  • aligned parameter descriptions with what's used in other docs
  • added missing params for StartSSOFlowParams

@alexisintech alexisintech force-pushed the laura/orgs-471-update-docs-for-clerkexpo branch from 29c7a0b to aba6dc2 Compare January 17, 2025 21:36
@alexisintech
Copy link
Member

Will test the custom flow code when the JavaScript PR is ready to merge/is merged.

Outstanding question:
I'm not seeing parameters for the useSSO() hook?

@LauraBeatris LauraBeatris force-pushed the laura/orgs-471-update-docs-for-clerkexpo branch from c5b9f1d to 81107e2 Compare January 28, 2025 22:24
@alexisintech alexisintech force-pushed the laura/orgs-471-update-docs-for-clerkexpo branch from fe5f63f to 1fff4b9 Compare February 4, 2025 21:35
Copy link
Member

@alexisintech alexisintech left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

wooooooooo !! 🥳

@alexisintech
Copy link
Member

oh wait, there's a TODO there for ya @LauraBeatris

@LauraBeatris
Copy link
Member Author

@alexisintech We need to merge https://github.com/clerk/clerk/pull/941 right after this one as well!

@LauraBeatris LauraBeatris merged commit 5c1d873 into main Feb 4, 2025
6 checks passed
@LauraBeatris LauraBeatris deleted the laura/orgs-471-update-docs-for-clerkexpo branch February 4, 2025 22:10
@LekoArts LekoArts mentioned this pull request Feb 6, 2025
1 task
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants