大佬们,这么写后,报了that.setData is not a function这么个错,咋办呐?Big guys, after writing this, I reported that.setData is not a function, what should I do?
大佬们,这么写后,报了that.setData is not a function这么个错,咋办呐?回答:
this.setData是小程序语法,你用的uniapp用vue语法,直接this.carList = res.data
data这里应该是这样写的
data: { action: '', ...}
箭头函数里面直接this.setData也可以了
哈哈哈嗝 看笑了