This is a contract that I made for study purposes of the cosmWASM framework. The idea behind it is a bonsai 🌳 shop platform, nothing serious, probably it contains some bugs too (🐜).
CosmWASM allows you to create, compile and build smart contracts on a cosmosSDK based blockchain.
To understand the framework better, please read the overview in the cosmwasm repo, and dig into the cosmwasm docs.
- Install the requested components and set up the environment.
- Clone the project: from your CLI
git clone https://github.com/bragaz/wasm-test-contract.git
- Move inside the project folder:
cd ../wasm-test-contract
- Run the docker command to compile the contract:
docker run --rm -v "$(pwd)":/code \ --mount type=volume,source="$(basename "$(pwd)")_cache",target=/code/target \ --mount type=volume,source=registry_cache,target=/usr/local/cargo/registry \ cosmwasm/rust-optimizer:0.10.4
- Inside the contract
helper.ts
file there is an example of how to try the contract