Authentication state including user, isAuthenticated, and tokens.
Throws
When used outside an AuthProvider.
Source
exportfunctionuseAuthState(): AuthStateContextValue { constcontext = useContext(AuthStateContext); if (context === undefined) { thrownewError("useAuthState must be used within an AuthProvider"); } returncontext; }
Accesses the authentication state context.