自定义tabBar不能使用wx.swichTab

发布于 7 年前作者 lding7870 次浏览最后编辑 7 年前来自 ask
  • 当前 Bug 的表现(可附上截图)

用tabBar组件,点击后无法利用wx.switchTab切换tab页面

  • 预期表现

预期切换到/pages/lostfound/index/index

  • 复现路径

https://developers.weixin.qq.com/s/JAVSlcmT7J8z

点击进入餐厅,点击下面的tabBar,预计切换到/pages/lostfound/index/index或者/pages/lostfound/home/home

  • 提供一个最简复现 Demo
2 回复
oshao
oshao1 楼6 年前

请问楼主这个问题解决了嘛

hantao
hantao2 楼5 年前

看了一下你的代码片段,使用方法不对吧?请按照文档上写的来 https://developers.weixin.qq.com/miniprogram/dev/framework/ability/custom-tabbar.html