Skip to main content

TypeAlias.BaseAuth

type BaseAuth = 
| {
isAuthenticated: undefined;
user: undefined;
}
| {
isAuthenticated: false;
user: null;
}
| {
isAuthenticated: true;
user: KeybanUser;
};

Represents the authentication state of the user.

This type can be one of the following states:

  • Unintialized:

    • user: undefined
    • isAuthenticated: undefined
  • Unauthenticated:

    • user: null
    • isAuthenticated: false
  • Authenticated:

    • user: KeybanUser
    • isAuthenticated: true