j***@163.com
j***@163.com
  • 发布:2023-08-29 15:00
  • 更新:2023-08-29 15:08
  • 阅读:98

在uni-app工程中的pages中定义了tabbar,如何控制在哪个页面是否显示?

分类:uni-app

pages.json配置如下

{  
    "pages": [{  
        "path": "pages/index/login",  
        "style": {  
            "navigationBarTitleText": "会员商城"  
        }  
    }, {  
        "path": "pages/index/index",  
        "style": {  
            "navigationBarTitleText": "会员商城"  
        }  
    },{  
        "path": "pages/member/memIndex",  
        "style": {  
            "navigationBarTitleText": "会员中心"  
        }  
    }],  

    "tabBar": {  
        "color": "#7A7E83",  
        "selectedColor": "#3cc51f",  
        "borderStyle": "black",  
        "backgroundColor": "#ffffff",  
        "list": [{  
            "pagePath": "pages/index/index",  
            "iconPath": "static/img/home.png",  
            "selectedIconPath": "static/img/selecthome.png",  
            "text": "首页"  
        }, {  
            "pagePath": "pages/member/memIndex",  
            "iconPath": "static/img/mem.png",  
            "selectedIconPath": "static/img/selectmem.png",  
            "text": "会员中心"  
        }]  
    }  

}

我想配置的tabBar 在指定页面显示,其余的页面不显示,怎么配置呢,我查看了 hbuiderx中自带的 hello uni-app demo,没看出哪里有特殊的配置啊,但是 它那个工程做到了 有的页面显示,有的页面不显示

也没有看到 显示调用uni.hideTabBar();

望大佬指点迷津

2023-08-29 15:00 负责人:无 分享
已邀请:
喜欢技术的前端

喜欢技术的前端 - QQ---445849201

tabBar下的list中配置的页面 就是要显示的,其余页面都不显示

要回复问题请先登录注册