微信小程序 tabber 的创建

 
 

在 app.json 里写下 如下代码  

"tabBar": {
    "selectedColor": "#1296db",
    "list": [
      {
        "iconPath": "image/pj.png",
        "pagePath": "pages/teachers/teacher",
        "text": "评教",
        "selectedIconPath": "image/pj.png"
      },
      {
        "iconPath": "image/info.png",
        "pagePath": "pages/myinfo/myinfo",
        "text": "我的",
        "selectedIconPath": "image/info.png"
      }
    ]
  }

iconpath  是小图标的路径  

pagepath 是跳转的页面

text 是写下的内容

selectediconpath 是点击是显示的图片的路径

selectedcolor  点击是 变色


猜你喜欢

转载自blog.csdn.net/woshigemengxin/article/details/80277720