npm install vuex-persistedstate --save
import Vue from 'vue'
import Vuex from 'vuex'
import getters from './getters'
import user from './modules/user'
import createPersistedState from "vuex-persistedstate"
Vue.use(Vuex)
const store = new Vuex.Store({
modules: {
user
},
plugins: [createPersistedState()],
getters
})
export default store