metaDAOproject / meta-dao-frontend

https://app.themetadao.org
Other
16 stars 16 forks source link

Add updated transaction lifecycle (send + confirm) logic #75

Open jshiohaha opened 2 months ago

jshiohaha commented 2 months ago

🚧 Logic should be ready for review, pending PR description & info

Minimum required code to invoke send and confirm a transaction (with defaults applied) 🙂 Otherwise, caller can pretty specifically define a variety of behaviors in both send and confirm logic.

// assume connection and tx are previously defined
const signature = await sendAndConfirmTransaction({
  signedTransaction: tx,
  connection,
});

Associated with the following FaaS task: https://github.com/orgs/metaDAOproject/projects/11?pane=issue&itemId=55984929