https://bonsai-exchange.web.app
This demonstrates the three important parts of a dapp and how they should be connected:
- The browser UI (ReactJS + Redux)
- ICON SDK for JavaScript
- SCORE (Python)
ICON Token Standard have used by app
- BonSai (IRC-3): Each Bonsai has id unique, name and price.
- Oxygen (IRC-2): Generate when user plant bonsai, use buy Bonsai.
Bonsai Exchange :
- Buy bonsai from stock
- Planting bonsai in the collection.
- After a certain period of time (30 second), each bonsai will photosynthesize some oxygen.
- Transfer bonsai to friend.
Future:
- The contract has the ability to update properties such as the life of a bonsai, which will display other forms of the bonsai such as sprouting, flowering, and fruiting.
- It is possible to resell the bonsai you have planted
If you are beginer, you would go a tour with app
You would be received 30 Oxygen to buy first Bonsai
Let's buy
Sign transaction with ICONex extension
Tada !
Buy Oxygen by ICX
Transfer Bonsai To Friends
Move Position Of Bonsai
mkdir keystoresCopy JSON file of keystore (download from wallet ICONex) to folder keystores
tbears deploy bonsai -k keystores/keystore.json -c config/deploy_bonsai_local.jsontbears deploy suncoin -k keystores/keystore.json -c config/deploy_oxygen_local.jsontbears txresult [txHASH]Copy the scoreAddress from the result
tbears deploy bonsai -k keystores/keystore.json -c config/deploy_bonsai_testnet.jsontbears deploy oxygen -k keystores/keystore.json -c config/deploy_oxygen_testnet.jsontbears deploy bonsai -m update -o [address contract] -k keystores/keystore2.json -c config/deploy_bonsai_testnet.jsontbears txresult <txhash> -c config/depoy_bonsai_testnet.jsondocker-compose updocker-compose exec Icon tbears deploy bonsai -k keystores/keystore.json -c config/deploy_bonsai_testnet.jsondocker-compose exec Icon tbears deploy oxygen -k keystores/keystore.json -c config/deploy_oxygen_testnet.jsonTestnet tracker: https://bicon.tracker.solidwallet.io/ put the score address
cd ui
cp .env.example .env
yarnCopy my info of wallet to .env
yarn startView in localhost:3000














