|
|
@ -5,7 +5,7 @@ import isDev from '../helpers/xutils' |
|
|
|
|
|
|
|
|
|
|
|
const ls = new SecureLS({ isCompression: false }) |
|
|
|
const ls = new SecureLS({ isCompression: false }) |
|
|
|
|
|
|
|
|
|
|
|
export default async({ store, $vuetify: { theme } }) => { |
|
|
|
export default async({ store, $vuetify: { theme }, route }) => { |
|
|
|
/** |
|
|
|
/** |
|
|
|
* |
|
|
|
* |
|
|
|
*/ |
|
|
|
*/ |
|
|
@ -36,27 +36,30 @@ export default async({ store, $vuetify: { theme } }) => { |
|
|
|
// if (process.client) {
|
|
|
|
// if (process.client) {
|
|
|
|
//
|
|
|
|
//
|
|
|
|
// window.onNuxtReady(async (nuxt) => {
|
|
|
|
// window.onNuxtReady(async (nuxt) => {
|
|
|
|
|
|
|
|
if (route && route.query && 'embed' in route.query) { |
|
|
|
createPersistedState({ |
|
|
|
window.rehydrated = true |
|
|
|
fetchBeforeUse: true, |
|
|
|
} else { |
|
|
|
async rehydrated(store) { |
|
|
|
createPersistedState({ |
|
|
|
window.rehydrated = true |
|
|
|
fetchBeforeUse: true, |
|
|
|
console.log(store.state.windows) |
|
|
|
async rehydrated(store) { |
|
|
|
console.log('Date difference ', await store.dispatch('windows/ActGetExpiryDate')) |
|
|
|
window.rehydrated = true |
|
|
|
}, |
|
|
|
console.log(store.state.windows) |
|
|
|
paths: ['users', 'sqlClient', 'apiClient', 'panelSize', 'windows', 'graphqlClient', 'apiClientSwagger', 'app'], |
|
|
|
console.log('Date difference ', await store.dispatch('windows/ActGetExpiryDate')) |
|
|
|
...( |
|
|
|
}, |
|
|
|
isDev() |
|
|
|
paths: ['users', 'sqlClient', 'apiClient', 'panelSize', 'windows', 'graphqlClient', 'apiClientSwagger', 'app'], |
|
|
|
? {} |
|
|
|
...( |
|
|
|
: { |
|
|
|
isDev() |
|
|
|
storage: { |
|
|
|
? {} |
|
|
|
getItem: key => ls.get(key), |
|
|
|
: { |
|
|
|
setItem: (key, value) => ls.set(key, value), |
|
|
|
storage: { |
|
|
|
removeItem: key => ls.remove(key) |
|
|
|
getItem: key => ls.get(key), |
|
|
|
|
|
|
|
setItem: (key, value) => ls.set(key, value), |
|
|
|
|
|
|
|
removeItem: key => ls.remove(key) |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
) |
|
|
|
) |
|
|
|
})(store) // vuex plugins can be connected to store, even after creation
|
|
|
|
})(store) // vuex plugins can be connected to store, even after creation
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|