I recently implemented user authentication in my react web app using Auth0. And I need to retrieve some information from user object. I did this so far:
cost { user, isAuthenticated } = useAuth0();
<p>{user.name}</p>
But I also want to get user's id, so I can reference them later in my backend. So I did this:
const { user, isAuthenticated } = useAuth0();
<p>{user.user_id}</p>
And when I go to the website I get undefined instead of the user's id.
Is it happening because I use dev-keys for my social connections, or maybe it has to be done differently?
useAuth0is a function that needs to be calleduseAuth0()? useauth.dev/docs/auth0console.log(user)?