i want to export from here is called use auth right so it's a custom hook right and as you can imagine this has got used as the fire name so that's why we want to do it okay so um nizar that's a good call thank you for mentioning that all right so at this point i'm going to go ahead and say return and i need to use something called the use context hook and you can see look it's already guessing what i'm doing which is awesome right i need to import use context from react and i want to actually pass in my auth context okay now when i actually come to use this you guys will see the amazing power that we have okay um guy indeed saying uh don't worry dude you're gonna see today that it does work i'll show you how to do it right so use auth and you can see use content okay so this is pretty much set up now okay so i want to show you guys how we can actually pull through this data and then i'll show you how we can enhance it afterwards okay so at this point imagine if the value over here that i passed through i'm just going to pass in something like you know user and let's just imagine the user was just sunny okay let's go ahead and hit save and then inside of our URL_TOKEN i'm going to go ahead and pull through my auth provider right so you see all providers come through oops hit save and let's just see if our app looks good at this point so let's go ahead and open it up and we can hit refresh and you're going to get used to coming back here and doing an r to refresh okay now you can see we're in the login to the app page so i want to check something i'm going to go to my login screen and i want to use that user okay so remember i showed you previously inside of the auth use auth file so i'm going to go ahead and pop this on my right hand side over here i showed you a second ago how we had the value being passed through here as user sunny so if i want to get that user information what i can do is i can say const and i can destruct the user from the use auth hook okay and i can import that and what's happening now is because it lies underneath that part of the tree as i mentioned over here because the auth provider wraps the stack nav again everything under the tree is then powered up with it you can go ahead and get this um get this information so at this point if i go ahead and say URL_TOKEN the user now what we should be able to see is if i refresh my app you can see when we touch the point here you can see the sunny comes through right so and by the way guys this is how you inspect the logs you can either do it here or you can do it with the export developer tools so if i see right now on the iphone NUMBER_TOKEN you can see it says uh where's it gone sometimes it comes through on here sometimes it does not in this case i haven't going up but the easiest way i'd say is check the console over here and that's how you console log out to a react native device okay in this case you can see log into the app and you can see we can actually pull through values from our context
NO_SEGMENT_TOKEN