@auth0/auth0-react
    Preparing search index...

    Function useAuth0

    • const {
      // Auth state:
      error,
      isAuthenticated,
      isLoading,
      user,
      // Auth methods:
      getAccessTokenSilently,
      getAccessTokenWithPopup,
      getIdTokenClaims,
      loginWithCustomTokenExchange,
      exchangeToken, // deprecated - use loginWithCustomTokenExchange
      loginWithRedirect,
      loginWithPopup,
      logout,
      } = useAuth0<TUser>();

      Use the useAuth0 hook in your components to access the auth state and methods.

      TUser is an optional type param to provide a type to the user field.

      Type Parameters

      Parameters

      Returns Auth0ContextInterface<TUser>