tabBar不显示
应该显示tabBar的。app.json代码如下
{
"pages": [
"pages/mypage/mypage",
"pages/logs/logs",
"pages/index/index"
],
"window": {
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#fff",
"navigationBarTitleText": "WeChat",
"navigationBarTextStyle": "black",
"enablePullDownRefresh":true
},
"tabBar": {
"color": "#000",
"selectedColor": "#56abe4",
"backgroundColor": "#fff",
"borderStyle": "black",
"list": [
{
"pagePath": "pages/mypage/mypage",
"text": "设置",
"iconPath": "icon/icon3.png",
"SelectedIconPath": "icon/icon3.png"
},
{
"pagePath": "pages/logs/logs",
"text": "日志",
"iconPath": "icon/icon2.png",
"SelectedIconPath": "icon/icon2.png"
},
{
"pagePath": "pages/index/index",
"text": "首页",
"iconPath":"icon/icon1.png",
"SelectedIconPath":"icon/icon1.png"
}
],
"custom": true
},
"networkTimeout":{
"request":30000,
"connectSocket":3000,
"uploadFile":3000,
"downloadFile":3000
},
"sitemapLocation": "sitemap.json",
"debug":true
}
我也是不显示,代码看了半天也没发现哪里写错了,控制台也没有报错
我找到了源代码,对比后发现,app.json中
"sitemapLocation": "sitemap.json",
"debug":true
应该改为
"debug":true
"sitemapLocation": "sitemap.json",
另外SelectedIconPath应该是selectedIconPath
非常感谢大家的热心解答,问题已经解决
自定义组件吗?还是原生的?这边测试没复现
我的不仅不显示,编译时直接提示tabBar那部分有问题。代码用的示例代码,应该不是代码问题。
你开启隐藏tabbar了吗?