微信小程序底部菜单详解

微信小程序底部菜单详解

只需要在app.json里面修改配置,即可
{
  "pages":[
    "pages/index/index",
    "pages/logs/logs",
    "pages/lation/index",
    "pages/videos/video"
  ],
  "window":{
    "backgroundTextStyle":"light",
    "navigationBarBackgroundColor": "#4682B4",
    "navigationBarTitleText": "微信测试",
    "navigationBarTextStyle":"white"
  },
  //以下就是底部导航的配置
   "tabBar": {
    "selectedColor":"#EEEE00", //选中时的颜色
    "backgroundColor":"#4876FF", //背景色
    "borderStyle":"white", //边框颜色
    "color":"white", //没有选中时的字体颜色
    "list": [{
      "pagePath": "pages/index/index",//导航所跳转的地址
      "text":"首页" //导航名称
    }, {
      "pagePath": "pages/logs/logs",
       "text":"日志"
    },{
      "pagePath": "pages/videos/video",
      "text":"视频库"
    }]
  }
}

如果还有疑问,可留言,或者扫面下方二维码进行提问
微信小程序底部菜单详解_第1张图片

你可能感兴趣的:(技术,it)