You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
12 lines
462 B
12 lines
462 B
/** 用户信息 **/
|
|
export const useToken = () =>
|
|
useState<string>('token', () => {
|
|
const token = useCookie<string | undefined>('token');
|
|
return token.value ? 'Bearer ' + token.value : '';
|
|
});
|
|
|
|
/** 登录弹层显示状态 */
|
|
export const useLoginDialogVisible = () => useState<boolean>('loginDialogVisible', () => false);
|
|
|
|
/** 注册弹层显示状态 */
|
|
export const useRegDialogVisible = () => useState<boolean>('regDialogVisible', () => false);
|