通过组件嵌套生成左侧列表略缩图时会产生内存溢出bug 等待修复

This commit is contained in:
pixelqm
2019-09-15 21:17:08 +08:00
parent c408911139
commit fe925eb763
6 changed files with 36 additions and 10 deletions
+9
View File
@@ -25,7 +25,13 @@ export const user = {
setExpiresAt(state, expiresAt) {
// 这里的 `state` 对象是模块的局部状态
state.expiresAt = expiresAt
},
clearAll(state) {
state.userInfo = {}
state.token = ""
state.expiresAt = ""
}
},
actions: {
async LoginIn({ commit }, loginInfo) {
@@ -58,6 +64,9 @@ export const user = {
},
token(state) {
return state.token
},
expiresAt(state) {
return state.expiresAt
}
}
}