0👍
✅
You have a reactivity caveat, so you should use this.$set
function :
.then(res => (this.$set(this.categories,id,res.name)));
and the id
property should be declared :
data() {
return {
categories: {
id:null
}
};
},
Source:stackexchange.com