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

Add the Expo Offline support page #1781

Open
wants to merge 15 commits into
base: main
Choose a base branch
from

Conversation

anagstef
Copy link
Member

@anagstef anagstef commented Dec 6, 2024

Explanation:

This PR:

  • Adds a new page that adds documentation for Expo offline support experimental feature.

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

@anagstef anagstef self-assigned this Dec 6, 2024
Copy link

github-actions bot commented Dec 6, 2024

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

@anagstef anagstef marked this pull request as ready for review December 6, 2024 16:33
@anagstef anagstef requested a review from a team as a code owner December 6, 2024 16:33
@alexisintech
Copy link
Member

posted my code review - let me know if it looks okay :)

@anagstef
Copy link
Member Author

anagstef commented Dec 9, 2024

@alexisintech Looks great! Thank you!

Can we also mark line 4?
import { secureStore } from '@clerk/clerk-expo/secure-store'

Copy link
Member

@royanger royanger left a comment

Choose a reason for hiding this comment

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

Glad to see this getting added (docs and the support both)!

docs/references/expo/offline-support.mdx Outdated Show resolved Hide resolved
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.

thanks for getting this in there!! looks great 😸💖

@anagstef anagstef force-pushed the stefanos/eco-257-add-a-docs-page-for-enabling-offline-support branch from 2a72633 to c4fc4e6 Compare December 10, 2024 16:13
@alexisintech
Copy link
Member

is offline support for expo web or expo native or both? it looks like the manifest organization got messed up

@alexisintech
Copy link
Member

waiting to see if the hooks are for native, web, or both

@anagstef
Copy link
Member Author

anagstef commented Dec 11, 2024

@alexisintech Both the hooks and the offline support are used only on the Expo native.

Got more info from the team and correcting myself here.

So:

  • Offline Support: Works only on native. If you use it on the Expo Web it simply does nothing.
  • useLocalCredentials() hook: Works only on native. On the Expo Web it won't cause issues, but it's like it does not exist (you always get null values for your local credentials).
  • useOAuth() hook: Works both on native and web. On the web you can also use the ClerkJS functionality to sign-in with OAuth as you would do in a web-only app, but we suggest to use the hook so that developers have a single code snippet for both web and native.

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.

woohoo 😸💖

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.

3 participants