I started my career as an Android developer many years ago, creating several Android apps, including one to help people remember names. I always wanted to create an iOS version of the app, but as I wasn’t an iOS developer, it seemed a daunting task. However, when the pandemic hit in 2020, I decided to use the extra time to develop a paid app for remembering names. In just two months, working in my spare time, I completed the app and released it for both Android and iOS.
Initially, this app was designed to help people remember names, but I soon realized it could also help users organize their contacts with multiple tags and grouping features. I added new functionalities like quizzes and in-app purchases. This project marked my transition to Flutter in 2020, and I thoroughly enjoyed the experience. Here’s a deeper dive into the pros and cons of Flutter, based on my journey.
Pros of Flutter
1. Single Code Base for Multiple Platforms: One of the most significant advantages of Flutter is the ability to write one codebase for multiple platforms, including Android, iOS, desktop, and web. This flexibility is a game-changer, eliminating the need to maintain separate codebases for different platforms.
2. Performance: Flutter compiles to native code, ensuring excellent performance and a smooth user experience. This is a major benefit compared to other frameworks.
3. Hot Reload: As an Android developer, I sometimes had to wait 20 minutes to see changes in the emulator or physical device. With Flutter’s hot reload feature, changes appear almost instantly, significantly speeding up development.
4. Widgets: Flutter’s building blocks are widgets. Everything is a widget, from buttons and text boxes to more complex components. This modular approach makes it easy to add, remove, or replace elements in your app, much like playing with Lego blocks.
5. Ease of Learning: Flutter is straightforward to learn, especially if you have experience with languages like Java or JavaScript. Even beginners find Flutter approachable thanks to its widget-based structure and the simplicity of the Dart language.
6. Community Support: Flutter has a thriving open-source community. You can contribute widgets, get help with issues, and find a wealth of resources and tutorials. This collaborative environment fosters rapid learning and development.
Cons of Flutter
1. Limited Platform Support: Despite its broad claims, Flutter doesn’t fully support platforms like watchOS, tvOS, or Apple CarPlay. Its web and desktop support, while available, isn’t as robust as its mobile support.
2. Larger App Sizes: Flutter apps are typically larger than native apps because they include rendering components within the code. This can be a drawback for users concerned about app size.
3. Lack of Third-Party Libraries: While Flutter excels in providing UI components, some SDKs available for Android or iOS may not be available for Flutter. This situation is improving, but it’s still a consideration.
4. Complex Native Functionality: For high-complexity apps requiring advanced native functionalities, Flutter may not be the best choice.
5. Delayed Availability of New OS Features: New features from operating systems might take time to be available in Flutter, which can be a slight inconvenience.
Real-World Application: Mi Story Builder App
I’d like to share my experience with Flutter through a mobile app we released last year called Mi Story Builder, designed to create stories for kids using ChatGPT. Here’s a quick overview of its development:
Features:
• Home screen with buttons to create a story, purchase credits, and share the app.
• Story creation involves selecting the type, characters, setting, moral, age, and gender.
• Integration with ChatGPT to generate stories.
• Options to view and manage past stories.
Development Journey:
• Proof of Concept: We started with a proof of concept (POC) to test the feasibility. Flutter enabled us to quickly develop and test this POC, confirming our approach.
• Requirements Gathering: We defined the features for the Minimum Viable Product (MVP). This stage involved significant discussion and refinement.
• High-Fidelity Design: Skipping the mockup stage, we directly created high-fidelity designs. Thanks to Flutter, our designers didn’t need to worry about the feasibility of their designs.
• Ticket Creation: We created a single set of tickets for the entire development team, streamlining the process.
• Development Time: The total coding time was about 50 hours, broken down into the initial POC, UI development, in-app purchases, and backend integration.
Overcoming Challenges
The journey wasn’t without its hurdles, particularly during the app store submission process:
• Apple’s Rejection: Our use of Firebase Analytics initially led to rejection due to privacy concerns, as the app targets children. We had to remove these libraries to comply with Apple’s guidelines.
• Parental Gate: Implementing a parental gate was another challenge. We creatively repurposed a PIN code widget to satisfy this requirement.
• Beta Version Bug: Testing on Apple’s beta version 17.1 revealed a bug, requiring additional troubleshooting.
Thanks to all the benefits of Flutter, we were able to release the app on both the Play Store and App Store in a record short time.
Conclusion
In 2021, Flutter overtook React Native as the most popular mobile app framework, and for good reason. Its ability to facilitate rapid development and consistent cross-platform design has made it a favorite among developers. While not perfect for every project, Flutter has significantly reduced my stress as a developer and enhanced my productivity. If you’re considering Flutter for your next project, I can confidently say it’s worth exploring. Happy coding!