Skip to content

Commit

Permalink
update perist key
Browse files Browse the repository at this point in the history
  • Loading branch information
Germey committed Dec 30, 2023
1 parent 13adbe4 commit c1b24ef
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 11 deletions.
1 change: 1 addition & 0 deletions src/store/chat/persist.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export default ['chat.applications', 'chat.conversations'];
1 change: 1 addition & 0 deletions src/store/common/persist.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export default ['user', 'token', 'setting'];
16 changes: 5 additions & 11 deletions src/store/index.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
import { createStore, ActionContext } from 'vuex';
import { createStore } from 'vuex';
import createPersistedState from 'vuex-persistedstate';
import midjourney from './midjourney';
import chat from './chat';
import root from './common';
import persistChat from './chat/persist';
import persistMidjourney from './midjourney/persist';
import persistRoot from './common/persist';

const store = createStore({
...root,
Expand All @@ -12,16 +15,7 @@ const store = createStore({
},
plugins: [
createPersistedState({
paths: [
'token',
'user',
'chat.applications',
'chat.conversations',
'midjourney.preset',
'midjourney.channel',
'midjourney.applications',
'midjourney.imagineTasks'
]
paths: [...persistRoot, ...persistChat, ...persistMidjourney]
})
]
});
Expand Down
1 change: 1 addition & 0 deletions src/store/midjourney/persist.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export default ['midjourney.preset', 'midjourney.channel', 'midjourney.applications', 'midjourney.imagineTasks'];

0 comments on commit c1b24ef

Please sign in to comment.