next/stores/autosaveStore.ts

19 lines
316 B
TypeScript
Raw Normal View History

import { defineStore } from "pinia";
export interface autoSavePayload {
draftId?: number;
fetchId: number;
}
export const useAutoSaveStore = defineStore("autosave", {
state() {
return {
draftId: undefined,
fetchId: 1,
} as autoSavePayload;
},
actions: {
async doSomething(did: number) {},
},
});