fix: 修复使用this语法时无法显示代码提示的问题并更新pinia相关语法

This commit is contained in:
xiaoxian521
2024-12-15 23:29:37 +08:00
parent b843eda26f
commit f8690a0b73
10 changed files with 22 additions and 18 deletions

View File

@@ -16,8 +16,7 @@ import {
import { useMultiTagsStoreHook } from "./multiTags";
import { type DataInfo, setToken, removeToken, userKey } from "@/utils/auth";
export const useUserStore = defineStore({
id: "pure-user",
export const useUserStore = defineStore("pure-user", {
state: (): userType => ({
// 头像
avatar: storageLocal().getItem<DataInfo<number>>(userKey)?.avatar ?? "",