用的web3.js,pc谷歌浏览器能正常唤起连接狐狸钱包,但是手机的钱包app试过了tp 狐狸钱包都不行,求大佬给段连接手机端钱包的代码
tp 是兼容metamask得api的,链接方式可以查看这里 初始化metamask
const accounts = await ethereum.request({ method: 'eth_requestAccounts' }); const account = accounts[0]; // We currently only ever provide a single account, // but the array gives us some room to grow.