What I learned by creating a Appwrite + Flutter demo
Jonathan Vanhaaften
Posted on October 30, 2021
Appwrite & Hackoberfest
I learned about Appwrite from the intro to this year's Hacktoberfest. Still in my learn phase of programing I wanted to learn more about this project and what I could do for Hacktoberfest. Last Hacktoberfest, the requirments of ciricleci's orb happened to be too much for me to accompish as a greenback. This year I hope to build a demo app for Appwrite, knowing nothing about flutter and still in the basics of React and Django.
Dart and the wonders of syntax
Dart happend to be a wonderful language - a mix of syntax I had seen on my voyage of trying to decide what language to learn and Youtube rabbitholes of tutorials. The one thing I encountered for the first time was that Appwrite is new and changing fast, and syntax that had been rendered redundent. This meant having to navigate and search the docs and forms to understand why the syntax in the tutorial was no longer useful and what to replace it with. With this I was able to see the progresson of Appwrite and how language evolves.
The whole I was lost in ...
this res.data
a getter for account.get had been made redundant. Being new to programing it took me days of Googling to understand and finally going for help on the Appwrite discord where I was helped to understand enough to fix the code.
Future<User> getUser() async {
final res = await account.get();
return User.fromMap(res.data);
}
to this:
Future<User?> getUser() async {
try {
return await account.get();
} on AppwriteException catch (e) {
debugPrint(e.message);
return null;
}
}
The App and where I ended up
Appwrite demo app count to quit
The app I decided to write was based on an old technique to quit smoking, where you initially start by counting the amount of cigarettes that you smoke. I also added in a cost element as incentive to decrease the count. It seemed simple and would have been for someone more experienced. I followed and learned a lot from React Bits (Damodar Lohani) and learned a lot by Frankenstein'n bits from his tutorials.
The App
Here are some screeen shots from the app. Only having a month I didn't do much in the design.
Login Page
Sign up page
The home page without data entered
The home page after data has been added an the appwrite datadase updated
Keep on plugging away
There is a lot of refactoring and design to do within this project and I'm excited to continue with it. Learning from Appwrite and Hactoberfest this October has shown me I have a long way to go but I am progressing, and that I do enjoy working on these projects. I would implore anyone looking to learn more about Appwrite to follow React Bits (Damodar Lohani).
Posted on October 30, 2021
Join Our Newsletter. No Spam, Only the good stuff.
Sign up to receive the latest update from our blog.