微信小程序tabbar不顯示解決辦法
更新時間:2017年06月08日 11:33:42 投稿:lqh
這篇文章主要介紹了微信小程序tabbar不顯示解決辦法的相關(guān)資料,需要的朋友可以參考下
微信小程序tabbar不顯示解決辦法
"pages":[ "pages/logs/logs", "pages/index/index" ],
微信小程序在測試tabbar的時候怎么都不顯示。
我就不貼api了。直接上代碼
{
"pages":[
"pages/logs/logs",
"pages/index/index"
],
"window":{
"backgroundTextStyle":"light",
"navigationBarBackgroundColor": "#fff",
"navigationBarTitleText": "小程序",
"navigationBarTextStyle":"black"
},
"tabBar":{
"selectedColor":"#dddddd",
"color": "#3cc51f",
"backgroundColor":"#ffffff",
"list":[{
"text" : "登錄",
"pagePath" : "pages/logs/logs",
"iconPath" : "image/12.png",
"selectedIconPath" : "image/12.png"
},{
"text":"注銷",
"pagePath" : "pages/index/index",
"iconPath" : "image/12.png",
"selectedIconPath" : "image/12.png"
},{
"text" : "日志",
"pagePath" : "pages/logs/logs",
"iconPath" : "image/12.png",
"selectedIconPath" : "image/12.png"
}]
}
}
這個json看了一天,直覺告訴我沒什么問題。實際上也沒什么問題。
但是tabbar怎么都不顯示。最后發(fā)現(xiàn)是
"pages":[ pages/logs/logs", "pages/index/index" ],
看標紅的問題。第一行絕對是不能配置為"pages/index/index"。所以我換成了pages/logs/logs要不然是不會顯示tabbar的
感謝閱讀,希望能幫助到大家,謝謝大家對本站的支持!
相關(guān)文章
JavaScript?定時器關(guān)鍵點及使用場景解析
這篇文章主要為大家介紹了JavaScript?定時器關(guān)鍵點及使用場景解析,有需要的朋友可以借鑒參考下,希望能夠有所幫助,祝大家多多進步,早日升職加薪2023-01-01
TypeScript新語法之infer?extends示例詳解
這篇文章主要為大家介紹了TypeScript新語法之infer?extends示例詳解,有需要的朋友可以借鑒參考下,希望能夠有所幫助,祝大家多多進步,早日升職加薪2022-08-08

