diff --git a/src/core/atom/auth.ts b/src/core/atom/auth.ts index 9bb7014b..963166bf 100644 --- a/src/core/atom/auth.ts +++ b/src/core/atom/auth.ts @@ -9,7 +9,7 @@ enum StateType { export const userTokenAtom = atom({ key: StateType.USER_TOKEN_ATOM, - default: null, + default: localStorage.getItem(USER_TOKEN) || null, effects: [ ({ onSet }) => { onSet((newToken, _, isReset) => {