mirror of
https://github.com/infiniflow/ragflow.git
synced 2026-07-25 18:03:29 +08:00
11 lines
248 B
TypeScript
11 lines
248 B
TypeScript
|
|
import authorizationUtil from '@/utils/authorizationUtil';
|
||
|
|
import { useState } from 'react';
|
||
|
|
|
||
|
|
export const useAuth = () => {
|
||
|
|
const [isLogin, setIsLogin] = useState(
|
||
|
|
() => !!authorizationUtil.getAuthorization(),
|
||
|
|
);
|
||
|
|
|
||
|
|
return { isLogin };
|
||
|
|
};
|