Open
Description
Version
3.5.1
Reproduction link
https://github.com/StephenBeirlaen/vuex-base-state-issue
Steps to reproduce
- Install a fresh vue install via the latest Vue CLI but custom build (I just used Vue 2.x and Vuex selected)
- add in a simple state in the vuex store (int: 0)
- add in a simple commit (updateInt(state) {state.int = 1})
- add in any component this.$store.commit('updateInt')
- make sure you do not have the "new vuex backend" option enabled in devtools settings(default)
- both your states in the vuex tab(base state and updateInt) will not show int as 1 instead of base state showing 0
OR
Use the provided repository and run:
- yarn install
- yarn serve
- steps from above
What is expected?
I expect time travel to work when jumping through the mutations history. A more recent mutation should not modify the mutations before that.
What is actually happening?
When the "new Vuex back-end" option is disabled:
When time traveling using the devtools to the different mutation states, the most recent state is always shown instead, even when jumping to the base state.
This int value should be 0 in the base state:
Reproduced on Chrome in Ubuntu 20.04 with devtools plugin 5.3.3 (latest)
This issue is fixed when enabling the "new Vuex back-end" option. However, since this is a stable release, the old version should also still work when it is not deprecated.