testShare.html 978 Bytes
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no, viewport-fit=cover">
    <meta http-equiv="X-UA-Compatible" content="chrome=1,IE=edge">
    <title>Title</title>
</head>
<body>
<div id="share"> 分享</div>
<script src="../build/sdk.js"></script>
<script>
    let shareData = {
        title: '国潮崛起年,中西碰撞博出位!',
        imgUrl: 'https://img01.yohoboys.com/o_1cnilugbs15ajak1gfo1d2h1p348.png?imageView2/1/w/200/h/200',
        desc: '这里有一份中西潮流榜单,请收好!',
        link: location.href,
        success: function () {
            alert('1123')
        }
    };
    // let sign = window.yo_sdk.wxSignature;
    //  sign().then(function(r){
    //      console.log(r)
    //      window.yo_sdk.wxShare(shareData)
    //  })

    window.yo_sdk.wxSignature(window.yo_sdk.wxShare(shareData));


</script>
</body>
</html>