Create a context to store authentication

This commit is contained in:
2023-06-15 08:45:21 +02:00
parent 10e5c124fd
commit 1934354665
10 changed files with 71 additions and 92 deletions

View File

@ -1,4 +1,3 @@
import { atom } from "jotai";
import { APIClient } from "./ApiClient";
export enum CreateAccountResult {
@ -30,8 +29,6 @@ export class AuthApi {
return localStorage.getItem(TokenStateKey) !== null;
}
static authStatus = atom(this.SignedIn);
/**
* Get user auth token
*/