onShareAppMessage(res) {
console.log(res)
if (res.from == "button") {
return {
title: '测试',
path: '/pages/index/index',
imageUrl: "../../images/usericon.png",
}
}
},
onShareAppMessage 设置无效,title及图片都无效,图片显示的是截图,title也是默认值 why?
2 个回答
你换我这个试试呢:
onShareAppMessage(res) { return { title: '[好友推荐]膳食营养科普知识', imageUrl: 'https://file.genepre.com/wechat/guide/sharefoods.png', path: `/pagesFoods/science/water?from=6`, }; },
具体实现可以参考这篇文章:
https://zhuanlan.zhihu.com/p/584480332?utm_id=0