wx.setTabBarBadge在IOS上text为空时显示异常
carNumber() {
if (this.globalData.carNumber != ‘0’) {
wx.setTabBarBadge({
index: 2,
text: this.globalData.carNumber+’’
})
}else{
wx.setTabBarBadge({
index: 2,
text: ‘’
})
}
},
怎么让text值为空或者为‘0’时,隐藏这个大红点,在安卓上面是可以的。

1 回复