5053关注15661浏览
你想反馈一个 Bug 还是 提一个需求?
Bug
如果是 Bug:
* Bug 表现是什么?
tabBar里的路由Url不能被其他地方正常跳转
预期表现是什么?
tabBar里的路由Url能被其他地方正常跳转
最近的更新版本之前是正常的
* 如何复现?
在最新版本
配置tabBar
在非tabBar页面里使用导航(navigator)跳转到tabBar里的Url
* 提供一个最简复现 DemoUrl
//app.json:tabBar 配置,配置两个Url,"pages/index/index","pages/profile/profile",或使用其他
"tabBar": {
"list": [
{
"pagePath": "pages/index/index",
"text": "首页",
},
{
"pagePath": "pages/profile/profile",
"text": "个人",
}
],
"color": "#8a8a8a",
"selectedColor": "#ff5406",
"backgroundColor": "#FFFFFF",
"borderStyle": "black",
"position": "bottom"
}
}
//页面跳转
在非tabBar页面里使用组件:
<navigator url="../index/index" hover-class="" open-type='navigate'>跳转到首页</navigator>
<navigator url="../profile/profile" hover-class="" open-type='navigate'>跳转到个人</navigator>
或
在js事件里使用:
toIndex: function () {
wx.navigateTo({
url: '../index/index',
})
都无法实现跳转。
而把url改为非tabBar 的url 就能正常调整,所以不会是其他地方的问题
-
至过去的我
2044人对此回答表示赞同
我是未来的你,你现在是不是在年找寻小程序答案。你不要感觉诧异,给你来信原因,就是让你不在后悔。今天去学习如何推广小程序,相信......点击查看更多>