import storage from "../../utils/storage";
export default {
  namespaced: true,
  state: {
    language: storage.get("language") || "cn",
  },
  getters: {
    language(state) {
      return state.language;
    },
  },
  mutations: {
    SET_LANG(state, lang) {
      state.language = lang;
    },
  },
  actions: {
    setLocalLang({ commit }, data) {
      commit("SET_LANG", data);
    },
  },
};
