import { defineStore } from "pinia";
import { getConfig } from "@/api/index.js";

const useStore = defineStore("main", {
  state : () => ({
    config: {
      tw: {},
      en: {},
      cn: {},
    }
  }),
  actions: {
    async getConfig() {
        let res = await getConfig();
        if(res.code === 200){
          this.config = res.data;
        }
    }
  },
  getters: {},
});

export default useStore;
