当我这里面请求的数据有空值的时候,我想显示文字提示,我该怎么做呢
title: (resp.data[i].username || "默认文本") + "-" + (resp.data[i].username || "默认文本") + "-" + (resp.data[i].username || "默认文本")
数直接输出数组是真的 你要用 resp.data[i].identities.length?resp.data[i].identities||默认文本 这样去写