The use of Vue.set is Vue.set (app.$data, 'baked, 2). Why do you add $before data?

Vue.set (app.$data, "baked, 2)

app.$data,
Why do you add $before data, and if you don"t add $, you will report an error

Mar.10,2021

app.$data is an instance attribute. You can read the data

in data .
the data object observed by the Vue instance. The Vue instance proxies access to its data object properties.

vue document
ide/instance.html" rel=" nofollow noreferrer "> ide/instance.html" rel= "nofollow noreferrer" > https://cn.vuejs.org/v2/guide.


if you take a separate data object, you don't need to add $; but you take the whole data option of Vue, of course you need to add it. For example:

var app = new Vue({
  data: {
    return {
      a: 10
    }
  }
})

Vue.set(app.$data, 'b', 3) // b
Vue.set(app.a, 'b',3) // ab
// 
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1eae729-21d8.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1eae729-21d8.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?