Skip to content

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

Merged
LauraBeatris merged 27 commits into
mainfrom
laura/orgs-471-update-docs-for-clerkexpo
Feb 4, 2025
Merged

LauraBeatris merged 27 commits into
mainfrom
laura/orgs-471-update-docs-for-clerkexpo

Conversation

@LauraBeatris

@LauraBeatris LauraBeatris commented Jan 16, 2025 •

Copy link
Copy Markdown
Contributor

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

@github-actions

Copy link
Copy Markdown
Contributor

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
Comment thread docs/_partials/expo/oauth-custom-flow.mdx
@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
Comment thread docs/references/expo/use-sso.mdx Outdated
Comment thread docs/references/expo/use-sso.mdx Outdated
Comment thread docs/references/expo/use-sso.mdx Outdated
Comment thread docs/references/expo/use-sso.mdx Outdated
Comment thread docs/references/expo/use-sso.mdx Outdated
Comment thread docs/references/expo/use-sso.mdx Outdated
Comment thread docs/references/expo/use-sso.mdx Outdated
Comment thread docs/references/expo/use-sso.mdx Outdated

<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
Copy Markdown
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
Copy Markdown
Contributor 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
Copy Markdown
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?

Comment thread docs/references/expo/use-sso.mdx Outdated
@victoriaxyz

victoriaxyz commented Jan 16, 2025 •

Copy link
Copy Markdown
Contributor

Hey @LauraBeatris, here's my review.

Update: d13a572

Notes

Comment thread docs/references/expo/use-sso.mdx Outdated
@LauraBeatris

Copy link
Copy Markdown
Contributor 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

alexisintech commented Jan 17, 2025 •

Copy link
Copy Markdown
Contributor

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
Copy Markdown
Contributor

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

@alexisintech alexisintech left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

wooooooooo !! 🥳

@alexisintech

Copy link
Copy Markdown
Contributor

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

@LauraBeatris

Copy link
Copy Markdown
Contributor Author

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

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.

4 participants