dwyl / dwyl/technology-stack

Flutter for Native Mobile Apps?

Open
#81 11 comments 3 reactions 1 assignee Claimed by @SimonLab View on GitHub
awaiting-review discuss enhancement priority-1 technical
Dominant language
JavaScript
Stars
291
Forks
25
PR merge metrics
No merged PRs in 30d

Description

Our plan for the next 6-12 months is to create _two_ apps:
1. @dwyl App = personal effectiveness: https://github.com/dwyl/product-roadmap#what - help people capture everything that is on their mind in order to de-clutter. Help them transform the raw text/thoughts into actionable items (_of various kinds_) and then focus on the most important items.
> The @dwyl App is our priority because we want to _use_ it to improve our personal effectiveness ASAP!
2. [@home](https://github.com/dwyl/home) App = all home-related functions e.g: to door entry, hot desk reservation, library book checkout, etc.

These two Apps have a decent amount of overlap: Auth, UI/Layout, Notifications,

Given that we would like to make the [@home](https://github.com/dwyl/home) App a _Native_ Mobile App so that it functions as _fast_ as possible, we spent a bit of time over the last few weeks investigating our options for writing a cross-platform native mobile app.

Our short-list included Ionic https://ionicframework.com and NativeScript https://www.nativescript.org but we quickly dismissed those because we want the benefits of _native_ performance not a "wrapped" JS (WebView) app with native components and APIs.

# Why Flutter?

@dwyl we have **guiding principals for technology selection** for the Apps we build: https://github.com/dwyl/technology-stack/issues/33

+ [x] 1. **Security**: advanced security features: https://flutter.dev/security
+ https://medium.com/@mehmetf_71205/securing-flutter-apps-ada13e806a69
+ [x] 2. **Accessibility**: Support for screen readers, high contrast and large fonts: https://flutter.dev/docs/development/accessibility-and-localization/accessibility
+ [x] 3. **Open Source**: Flutter was initially developed by Google but has since been spun out into an independent GitHub Org. Google still handles security reporting and that's a _good_ thing because you know someone at Google is _responsible_ for acting _fast_ when a security report is made.
+ [x] 4. **People Centric**: the fact that it can ship to _any_ device/platform makes it _very_ people-centric because the UX will _great_ no matter where the person is using it.
+ Gorgeous _Native_ User Interaction including built-in support for gestures, voice, transitions and animations. These might feel like "nice to have" but some people _really_ love these micro-interactions.
+ Native performance up to 120fps means buttery smooth UI anywhere (_where there is a display with a sufficiently [high refresh rate](https://youtu.be/-2pffpPl1lQ?t=197)_) because of the Dart compiler.
+ [x] 5. **Mobile First**: the _first_ platform Flutter targeted was (_Native_) Android. Flutter is still predominantly used for Mobile UI but it can be used to build Desktop, Google Assistant, Web Apps and "Ambient Computing"! See: https://flutter.dev/showcase and https://youtu.be/NfNdXgJZfFo?t=884
+ [x] 6. **Responsive**: The Flutter UI framework is designed to work on _any_ screen size without the Dev(s) having to jump through hoops to check the device width/height and debug random screen sizes!
see: https://flutter.dev/docs/development/ui/layout/responsive
+ [x] 7. **Offline First**: SQLite database for caching/storing data locally:
https://flutter.dev/docs/cookbook/persistence/sqlite
+ [x] 8. **Developer _Effectiveness_** - from everything we have seen - excellent documentation, regular predictable releases, good IDE support and stateful hot-reloading for rapid development - we are keen.
+ [x] 9. Internationalisation: Flutter has been built for internationalisation from the start: https://flutter.dev/docs/development/accessibility-and-localization/internationalization
+ [x] 10. Custom UI: with Material Theming, Devs/Designers can have _full_ control over the UI see:
https://www.youtube.com/watch?v=NfNdXgJZfFo&list=PLjxrf2q8roU0o0wKRJTjyN0pSUA6TI8lg

With that in mind we have tasked [padawan](https://en.wikipedia.org/wiki/Jedi#Padawan) @miguelmartins17 - who has [experience](https://github.com/miguelmartins17/Englisher-and-Englisher-Game) of building Native Android Apps - with being our [sherpa](https://en.wikipedia.org/wiki/Sherpa_people#Mountaineering) in exploring this _exciting_ tech! He is on a [_mission_](https://github.com/dwyl/start-here/blob/master/mission.md) to become a Flutter _Expert_ in the next 6 months and make the journey as easy as possible for everyone that follows!

> **Note**: I (Nelson) planning to invest 2 weeks to learning Flutter _soon_ to determine if it can be our front-end tech of choice. I am currently doing work for [@home](https://github.com/dwyl/home) so I need to figure out when I will have time ... 💭

# _Google_ ...

Google is investing _heavily_ in Flutter and they are using Flutter for several of their cross-platform Native Mobile Apps including Google Assistant, Google Adds (_their main money maker_) and ***Stadia*** their recently launched gaming platform.
https://flutter.dev/showcase

![google-apps-built-with-flutter](https://user-images.githubusercontent.com/194400/71911727-267a4e00-316c-11ea-9ad9-49755641affb.png)

This is not a _reason_ to use a particular technology, but the fact that they are backing it and using it for their apps means it's a decent bet.

# Proposal

I propose that we _investigate_ using Flutter for cross-platform mobile apps.
My first objective is to test Flutter Web and see how easy it is to build a PWA: https://github.com/dwyl/learn-flutter/issues/9
Then I will attempt re-use the same code for an Android Native App.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.