uniapp 小程序 vue TypeError: Cannot read property ‘toString‘ of undefined

在这里插入图片描述

是因为对字符串使用toString的时候页面中的数据还没有加载 。

错误代码:
在这里插入图片描述

可以使用 v-if
修改为:
在这里插入图片描述

猜你喜欢

转载自blog.csdn.net/maoge_666/article/details/131591928