CupThread React Native & Expo SDK - v0.1.0
    Preparing search index...

    Function useCupThreadUserToken

    • Hook retrieving the current user or device authentication token.

      Returns string

      Active user token string. Inside a <CupThreadProvider> without an explicit userToken prop and with an async storage adapter configured, this is '' until the persisted token resolves — gate token-dependent fetches on useCupThreadTokenReadiness().

      function UserHeader() {
      const userToken = useCupThreadUserToken();
      return <Text>User ID: {userToken.substring(0, 8)}</Text>;
      }