Upgrading vuex 0.3 to 0.4
Breaking0.3.0 → 0.4.2Breaking2New5Changed1Other1
BreakingUpgrade verdict
2 breaking changes.
In plain terms
- You can no longer call actions through the store object. Instead, import the action in your component and bind it with the new vuex option.
- Passing mutations as an array to the store constructor no longer works. Use the new modules option to group state and mutations instead.
Must act 2 items need code or config changes
What you must change
Breaking2
Actions are no longer exposed on the store; import them directly in components and bind them with the new
vuex option.vuexThe
mutations option no longer accepts an Array when creating a store; use the new modules option for composing state and mutations.mutationsmodules