- 
                Notifications
    You must be signed in to change notification settings 
- Fork 851
Chris/mobile 279 expo sign in with apple #2732
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
base: main
Are you sure you want to change the base?
Conversation
…ce clarity on testing and configuration steps
| The latest updates on your projects. Learn more about Vercel for GitHub. 
 | 
Fix for vercel builds.
…eSignIn()` documentation
| Overall this looks great @chriscanin! I left just a few comments and I'll leave the technical review to the js team and the content review to the docs team 😃 Nice first docs PR! 🚀 | 
| 
 Hey @mikepitre , did not see any comments here on this repo. Maybe they were not published if it was a review? Let me know! | 
| 
 you are correct, I never hit submit. They should be there now 🙈 | 
| @chriscanin @mikepitre @alexisintech - have just submitted a docs review. Have a look, and let me know thoughts. I will also leave some comments about certain things I'm hesitating about before I can approve, and want Alexis to have a second look as well. This is a great addition Chris, thank you 🚀 | 
| ## Error handling | ||
|  | ||
| The `useAppleSignIn()` hook may throw errors in the following scenarios: | ||
|  | ||
| - **User cancellation**: The user cancels the sign-in flow, resulting in an error with code `ERR_REQUEST_CANCELED`. | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we perhaps want this in the guide itself as well?
        
          
                docs/guides/configure/auth-strategies/sign-in-with-apple.expo.mdx
              
                Outdated
          
            Show resolved
            Hide resolved
        
      …ion and examples
I like the link to the what is page from apple, very informative! Co-authored-by: Michael Novotny <[email protected]>
…o the Sign in with Apple guide
| @chriscanin Have just pushed a docs review pt 2 here. Here is what I've done: 
 Hope that makes sense but hit me with any questions/ thoughts if any. Tagging you @alexisintech for visibility on this too. Approving this but want you to have a final look! | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is looking great! there are a few questions I have regarding the examples. I'm going to contribute a commit to clean things up, but curious to hear back about these comments!
| import { Text, TouchableOpacity, StyleSheet, Alert, Platform } from 'react-native' | ||
|  | ||
| export default function SignInPage() { | ||
| const { signIn, setActive, isLoaded } = useSignIn() | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not sure how this got added! the useSignIn() hook isn't used
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ahh good catch. I pulled the example from the quickstart repo, and took out the logic where these are used in the "signInPage", but did not remove the imports or this line.
| import { Text, TouchableOpacity, StyleSheet, Alert, Platform } from 'react-native' | ||
|  | ||
| export default function SignUpPage() { | ||
| const { signUp, setActive, isLoaded } = useSignUp() | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same, not sure how this got added, the useSignUp() hook isn't used
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| </Tab> | ||
|  | ||
| <Tab> | ||
| The following example demonstrates how to implement a reusable component that works on both sign-in and sign-up pages. | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it kinda feels like three of the same exact example - I'm going to work up something to consolidate these
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sounds good! I am onboard.
| }) | ||
| ``` | ||
|  | ||
| ## Error handling | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i love this section 😸💖
| alrighty, i've posted my docs review! 
 | 
| looks like we're getting a warning about the partials, but they are indeed working locally. @NWylynko could you take a look? i think its because the build script wants the full path    i'm going to mark this PR as blocked for now | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@alexisintech Curious to know why we're adding the partial here rather than in the general _partials folder?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
its a relative partial - nick is going to add more info to our CONTRIBUTING doc about them, but we support relative partials now !
|  | ||
| ## Build your authentication flow | ||
|  | ||
| <Include src="../../../reference/expo/_partials/use-sign-in-with-apple-example" /> | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure a relative partial makes sense if its gonna be used here.
🔎 Previews:
https://clerk.com/docs/pr/chris-mobile-279-expo-sign-in-with-apple/expo/getting-started/quickstart
https://clerk.com/docs/pr/chris-mobile-279-expo-sign-in-with-apple/expo/guides/configure/auth-strategies/sign-in-with-apple
https://clerk.com/docs/pr/chris-mobile-279-expo-sign-in-with-apple/reference/expo/use-apple-sign-in
What does this solve?
This documentation helps to better explain the process of adding a native apple sign in / sign up button to your expo application in iOS.
What changed?
I have added a created an apple sign in installation guide, and added a hook details page. I have also added these items to the side menu as they are placed in the iOS section, so that the expo documentation matches as closely as possible.
Checklist