<body style="background-color: #ededed">
<div id="webapp" class="wexin-launch-btn">
<wx-open-launch-weapp id="launch-btn" username="gh_" path="pages/index/index.html" >
<template>
<img class="btn" style='width:100%;' src="https://1.png" border="0" width="100%" >
</template>
</wx-open-launch-weapp>
</div>
</body>
<script type="text/javascript">
wx.config({
debug : false,
appId : '',
timestamp : '',
nonceStr : '',
signature : '',
jsApiList : [],
openTagList : [ 'wx-open-launch-weapp' ]
// 可选
});
var btn = document.getElementById('launch-btn');
btn.addEventListener('launch', function(e) {
console.log('success');
});
btn.addEventListener('error', function(e) {
console.log('fail', e.detail);
});
</script>
jsApiList: [''],
不能为空
你好,IOS正常吗?提供下复现的链接。