Skip to main content

分享给好友的方法

share2WechatMoments

tip

直接跳转到微信朋友圈分享的方法

分享给好友的方法

属性类型默认值是否必填描述
titlestring分享标题
descstring分享描述
linkstring分享连接
imgUrlstring分享图片
successfunction接口调用成功的回调函数
failfunction接口调用失败的回调函数
completefunction接口调用结束的回调函数(调用成功、失败都会执行)

示例代码

tip

如果参数没有传分享信息, 则取updateShareData的初始分享信息

dsBridge.call(
'share2WechatMoments',
{
title: '辅城',
desc: '分享描述',
link: 'https://m.fccn.cc',
imgUrl: 'https://m.fccn.cc/shareLogo.png',
success(res) {
console.log(res)
}
}
)