This is a simplification of #86, getting rid of the handy .ts files which would be auto-generated by a new soroban-cli command like soroban contract bindings --ts, and instead shows how the new soroban-cli library could be used on its own, even before new features land in the CLI.
This does not provide the handy typeahead and documentation that generated TS files would give, but it already greatly simplifies encoding all of the arguments. And if you provide misformatted arguments, the createOp call would fail, which means you would see a (somewhat) useful error message before firing the RPC call and awaiting its return.
See Enabling Dapp Developers proposal for full context.
This is a simplification of #86, getting rid of the handy
.ts
files which would be auto-generated by a newsoroban-cli
command likesoroban contract bindings --ts
, and instead shows how the newsoroban-cli
library could be used on its own, even before new features land in the CLI.This does not provide the handy typeahead and documentation that generated TS files would give, but it already greatly simplifies encoding all of the arguments. And if you provide misformatted arguments, the
createOp
call would fail, which means you would see a (somewhat) useful error message before firing the RPC call and awaiting its return.