#how to use token in a soroban smart contract
12 messages · Page 1 of 1 (latest)
Hey @indigo plinth, you need to wrap the Stellar classic asset to get the Address of the Stellar Asset Contract (SAC)
Allows the user to use their Stellar account and trustline balance on Soroban using the Token Interface, which is similar to the ERC-20 token standard.
The wrapping is only done with soroban cli. Is there not a way of wrapping with the soroban js client
I am building a dApp that involves the use of stellar Asset.
My users would not understand wrapping asset because they are not going to be tech savvy
All they have would be a code and issuer address
Is there not a way of wrapping it via the soroban js client
So you want to use the token with js? Or within a smart contract?
This can be helpful
https://github.com/esteblock/token-playground
https://token-playground.gitbook.io/guide/
Thanks
Does anyone know how to interact with a getter function via js. I mean smart contract function that don't retrieve info only and does one pay gas fee for this
Js without frontend?
You can get a ledger entry or index emitted events to get data without a getter or gas. There are some examples in the rpciege game
But youre gonna wanna use js-soroban-client for now
I used server.simulateTransaction
To get data? Can i see hoe?
Can u show me ?