react h5 打开微信小程序
h5打开微信小程序// 在didmount中监听launch 需要注意一点的是 一定在wx.ready中监听useDidmount(() => { wx.ready(() => { const launchBtn = wxLaunch.current; (launchBtn as any).addEventListener('launch', function (e: any) { console.log('success'); }); (launchBtn as any)
原创
2021-08-02 17:45:57 ·
679 阅读 ·
2 评论