@serenity-is/corelib / Authorization / isLoggedIn

Variable: isLoggedIn

isLoggedIn: boolean

Defined in: src/base/authorization.ts:152

Checks if the current user is logged in. Prefer isLoggedInAsync as this one might block the UI if the UserData is not already loaded.

Returns

true if the user is logged in, false otherwise.

Example

if (Authorization.isLoggedIn) {
    // do something
}