1.阻止事件传递
不用bindtap,用catchtap阻止冒泡
2.wx.navigateTo传参
bindViewTap: function() {
wx.navigateTo({
url: '../logs/logs?name=hello'
})
},
接收页面
Page({
data: {
nickname:'default',
logs: []
},
onLoad: function (query) {
this.setData({
nickname:query.name
});
}
})
网友评论