1👍
This is a default behavior and i think it is okay like that.
Otherwise the users must login after each App update.
But of course there are situations where you have to migrate your stored data.
Thats why i run a migrations in main.js which just compares both versions (the currentAppVersion and the storedAppVersion)
If you want to delete all content from localStorage you must go to
Settings->Apps
search your App and there klick on storage.
Now you have 2 Buttons to delete everything.
Hope that helps you
- [Vuejs]-What would be the best way to check if any of the keys in an array of objects contain a value from an object of arrays array?
- [Vuejs]-Vue.js: Add every new items to the top of the table
0👍
I managed to use a reducer for Vuex Persist to exclude the ‘appVersion’ value from the store.
const vuexPersist = new VuexPersist({
key: 'appStore',
storage: localStorage,
reducer: state => // exclude certain values from being persisted
Object.keys(state).reduce((acc, curr) => {
if (!['appVersion'].includes(curr)) acc[curr] = state[curr];
return acc;
}, {}),
});
Source:stackexchange.com