While working on our own dApps ive come to realize that there is a lack of VeChain utilities for flutter. Although we can repurpose some Ethereum packages, it is quiet time-consuming and some things that we need in VeChain are not supported with those packages. This is where we had the idea to code and publish our own VeChain specific packages for Flutter. We decided to translate thor-request.py to dart, since this python library has almost all abilities to interact with the blockchain tht we would use in our current projects.
The first step was to take a look into the thor-request.py I decided to first translate the entire code of this library one to one to dart. This process took while since i myselfe am not too familiar with python. Once the whole library was translated i sarted testing my code. I then fixed the code whenever a test failed until all my tests passed.
Quiet a bit of code had to be changed to work in dart, since some dependencies that thor-request.py uses had no equivalent package in dart. So i had to dig around theinternet to find existing flutter packages that could do what i want or write code that thor-request.py simply imports from a dependency for our package as well. One of the bigest issues was encodeing parametertypes together with parameters, which was needed for the deployment of contracts. It took a long time until i found a single, outdated package tht does this. Although i had to adjust the code of this package quiat a bit, it would have taken me a lot longer to write all of it from the ground up.
Log in or sign up for Devpost to join the conversation.