TownSquareXYZ / tonconnect-ui-vue

TonConnect UI Vue is a Vue UI kit for TonConnect SDK.
Apache License 2.0
21 stars 6 forks source link

tonConnectUI.setConnectRequestParameters can't work #13

Closed TroyMa1990 closed 1 week ago

TroyMa1990 commented 1 month ago

these code can't work, can't receive wallet.connectItems?.tonProof, please help, thank you!

  const payload = { tonProof: "xxxxxxx" };
  tonConnectUI.setConnectRequestParameters("ready",state: "ready",value: payload);
  tonConnectUI.onStatusChange(wallet => {
  if (wallet.connectItems?.tonProof && 'proof' in wallet.connectItems?.tonProof) {
  ..
  }
  });
ngocdangrby commented 1 month ago

same here

ngocdangrby commented 1 month ago

i found this method to set proof in the doc. and its worked

tonConnectUI.setConnectRequestParameters({
    state: 'ready',
    value: {
        tonProof: '<your-proof-payload>'
    }
});
sansx commented 1 month ago

@TroyMa1990 hey! which version of tonnect-ui-vue, and vue are you using now, you can check our demo repo first, it should have fully example there, https://github.com/TownSquareXYZ/demo-dapp-with-vue-ui/tree/main