What is Flutter?

It sounds like the name of a betting app but Flutter is a cross-platform mobile development system powered by Google’s Dart language.

Google bought a gesture recognition company called Flutter in 2013. Now, four years on Flutter appears to be earmarked as the UI for their new operating system Andromeda.

Cross-platform Mobile Development

There are a number of different development system for developing iPhone, Android and sometimes Windows Phone apps. These are often JavaScript based or less commonly native in C# or other languages. Native takes longer to develop but runs faster than JavaScript though In many cases JavaScript apps are all you need.

Flutter produces native code despite being programmed in Dart which is used in web development and can output JavaScript. However Dart can be compiled to produce Ahead of Time (AOT) machine code. This is a security requirement of iOS that all apps code must be pre-compiled before submission to Apple’s App Store.

It makes economic sense to use the same programming language for both platforms. Typically between 10-15% of a cross-platform app’s code is specific to each platform and the rest is common. That’s almost half the effort (115% vs 200%) compared to developing each platform in its native language (Swift vs Java).

Flutter UI

But the Flutter team have gone one step further. With other cross-platform mobile dev systems like Xamarin, though they share the same programming language, each platform still has a different UI to be coded. On iOS you have to worry about View Controllers and Views, while Android has Activities etc.

Not so with Flutter, they have sought to remove that 10-15% effort by using the same UI for both platform. All the UI features such as gestures, widgets, animations and so on are the same for both platforms. This means that iOS Flutter Apps will look like Android 5 Apps as Flutter’s UI is based on the most recent Android design philiosophy known as Material Design.

Not only that, but the UI has been designed for high performance which they define as achieving 120 frames per second. This is an interesting target and it means that Flutter apps should be both smooth and responsive to users. There’s some clever code going on behind the scenes and I’m guessing it involves heavy use of the built-in GPU chips. I suspect, but can’t confirm that it will probably not work on older phones more than three to four year.

What Do I need to develop for Flutter

Flutter is currently only for Mac or Linux with Windows coming in the future. Although it lets you develop for Android or iOS, you do need a Mac for iOS development with Xcode 7.2 or higher and to deploy apps in the App Store needs you to be a registered Apple developer.

Installing Flutter is straightforward but is only half the story. After installing it, you need to install further dev tools. On Mac you need to install Xcode 7.2 or higher and for Android development on Mac or Linux, you need the free community edition of JetBrain’s Intellij IDEA. Ironically you can’t use Android Studio which is based on JetBrain’s IntelliJ IDEA because the Flutter plugin currently only works in Intellij IDEA and not Android Studio.

Notes on Flutter and Dart

For developers, the tool set is critical. Google had originally developed their own IDE for Dart but switched to Intellij Idea with a Dart plugin. This plugin supports many features such as syntax highlighting, code completion, analysis, refactoring, debugging, and more.

Conclusions

It’s still relatively early but the Flutter website documents it well. If you’re looking for a zero cost cross-platform development system, it may be well worth a good look. It depends on how you feel about Dart.

One thing I haven’t seen any examples of is using mobile phone features such as GPS, navigation, cameras etc. This examples file is short and there needs to be a lot more. The flutter docs website is a good place to start, seeing what features are available in the API.

There doesn’t seem to be any way to request a minimal set of requirements needed for an App to successfully launch. A photography app for example is going to need at least access to cameras, and somewhere to store images plus all the various permissions.

So it’s fair to say this is still a work in progress.

Additions

As I was preparing this article, I came across this article about Google’s new Operating System Andromeda and it gives Flutter some context as the UI framework for Andromeda.
If you wish to see more about Flutter, this 24 minute Youtube keynote video by the Flutter team provides some background

Post a Comment

Your email address will not be published.