fix(#2): 修复无法创建文件的问题

This commit is contained in:
BTMuli
2023-03-08 08:15:26 +08:00
parent 6231730e49
commit 1b61793970
2 changed files with 15 additions and 3 deletions

View File

@@ -1,6 +1,6 @@
import { defineStore } from "pinia";
export const useAppStore = defineStore({
const useAppStore = defineStore({
id: "app",
state: () => {
return {
@@ -8,7 +8,15 @@ export const useAppStore = defineStore({
sidebar: {
expand: true,
},
dataPath: "",
};
},
actions: {
setDataPath(path: string) {
this.dataPath = path;
},
},
persist: true,
});
export default useAppStore;