Vue common mistakes and points of attention

Error caused by initial value

Reason: The DOM has loaded the data and has not received a 404 error.
Insert picture description here
Solution: Use v-if to judge that the data is loaded before rendering the DOM
Insert picture description here

Expected Object,got Number with value 95

Insert picture description here

el-option requires valueInsert picture description here

TypeError:Cannot read property ‘key’ of undefined

Insert picture description here

EXpected Object,got String with value “rules”

  • The string without the colon
    Insert picture description here

Object(…)is not a function

  • Import and export errors

Insert picture description here

Missing required prop:“value”

  • el-select requires v-model
    Insert picture description here

Failed to resolve directive:mode

  • The instruction is wrong

Insert picture description here

Guess you like

Origin blog.csdn.net/weixin_44757417/article/details/108893418