import { unref } from "vue"; import { defineStore } from "pinia"; import axios from "axios"; import { useAxios } from "@vueuse/integrations/useAxios"; const baseURL = import.meta.env.VITE_DOMAIN_URL; const instance = axios.create({ baseURL: baseURL, }); export const useInfoStore = defineStore({ id: "info", state: () => { return { poster: [], exhibition: [], activity: [], news: [], notices: [], }; }, getters: {}, actions: { async getPoster() { const { data } = useAxios( "/show/poster/getList", { method: "get" }, instance ); console.log("data", data); this.poster = data; }, getData() { const { data, isFinished } = useAxios( "/show/poster/getList", { method: "get" }, instance ); }, }, });