3π
β
It is just a shorthand for old: new Vue({data() { return {...}; } })
.
If you need data which is shared between components you had to create new Vue(...)
. Now you can use observable β Vue.observable({...})
and use it in render-functions or computeds.
So, I think it is not Vuex replacement, because Vuex cares about global App data and has nice debug tools.
π€gleam
Source:stackexchange.com