添加了localStorage支持
This commit is contained in:
parent
c96252d46c
commit
b50a4c9177
@ -1,4 +1,5 @@
|
||||
import axios from 'axios';
|
||||
import createPersistedState from 'vuex-persistedstate';
|
||||
|
||||
const state = {
|
||||
isAuthenticated: false,
|
||||
@ -35,6 +36,12 @@ const getters = {
|
||||
token: (state) => state.token,
|
||||
};
|
||||
|
||||
const plugins = [
|
||||
createPersistedState({
|
||||
storage: window.localStorage,
|
||||
}),
|
||||
]
|
||||
|
||||
export default {
|
||||
namespaced: true,
|
||||
state,
|
||||
|
||||
Loading…
Reference in New Issue
Block a user