My First Flutter Experience as a Native Android Dev! š
First a little background.
I have been developing native Android applications for quite some time now and had always heard of Flutter being the new framework in town for application development. Now, if youāre reading this, thereās a high chance you know what Flutter is, so I wonāt be going into that. What Iāll do instead is explain how I, a native Android developer, feel about it. š
How I Started
Like always, I started reading the official Docs and supplemented it with a tutorial that covers the framework basics. This time, I chose something different: FreeCodeCampās Flutter Tutorial created by Vandad Nahavandipoor. One of the longest videos on FCC, yet filled with so much valuable content and such a great teacher. Itās a must watch, seriously.
What I Built?
After reading the docs and getting familiar with Flutter, I felt confident in my Flutter skills, knowing I could create basic apps with functionality and design. Then came an assignment from a company hiring Flutter developers. I thought it was a great challenge to test my skills, and this app is the result of that assignment. (video here)
Press enter or click to view image in full size
How I Built It?
Itās a very simple app. It fetches news from the NEWS API using the āDioā package and displays a list of the news. I also added a search bar to let users search for specific news articles. Sounds very simple, and it was to an extent but for a beginner like me, it was a great challenge which I accomplishedš
Letā s talk about the Prosā¦
Declarative UI: Itās a breath of fresh air! Coming from XML-based UI design, while XML wasnāt perfect, it got the job done. However, managing separate files for UI and logic often became hectic. In Flutter, you simply code what you want. While I havenāt used it extensively, it already feels great. šØ
The Packages: The variety of community-made packages is astonishing! As a developer, I can use these packages to simplify tasks. Native Android also has libraries, but Flutter has more variety, and adding them is super simple: just run flutter pub get package_name. š
Cross-Platform: This oneās no secret: code for one platform, and it runs everywhere! I can run the app on my Android device, iOS, or even as a website on Chrome. Although I havenāt tried desktop (Windows/macOS/Linux) or embedded devices yet, itās amazing to think a single change, like updating a button color, works across all platforms! Mind-blowing. š±
ListView.builder: As someone who has implemented RecyclerView countless times in native Android, I can confidently say ListView.builder is a game-changer. Itās so much easier and cleaner to implement. And honestly, I donāt want to go back to RecyclerView ever again! š
And the Consā¦
The Setup: Maybe itās just me, but I struggled to get everything set up properly. Despite having VS Code, Android Studio, Java SDK, Flutter, and everything else installed, I kept encountering errors. After reading numerous Stack Overflow posts and using AI assistance, I finally got it working. Adding Firebase was another challenge, but in the end, it works beautifully. š
Realtime Visual Updates: While Hot Reload is amazing and almost instantly updates the UI (seriously, how do they achieve that without rebuilding the app?!), I still miss the natural feel of XML. With XML, you can visually move views on-screen and then fine-tune them. In Flutter, especially as a beginner, you need to have a mental image of how widgets will interact. It hasnāt fully clicked for me yet, but I hope it gets easier with experience. š±
Conclusion!
So far I like it. With time who knows where flutter will be. With more experience I will get better at flutter and then maybe I will write an update to this one
Learn about Mediumās values
Iām still a beginner, so some of the things you might find as pros or cons arenāt mentioned here, or you may disagree with my take ā and thatās okay! After all, this was my experience with Flutter, and yours could be different.
Feel free to correct me if Iām wrong somewhere, or share your own pros and cons in the comments. š
āØSource code for the app.
This is my first time writing for Medium so I will really appreciative if you could tell if you like it.
You can contact me hereā¦
š§ Email: contactsheikhasifali@gmail.com
š LinkedIn
š» GitHub
š Portfolio
Thanks for reading.