BT

Facilitating the Spread of Knowledge and Innovation in Professional Software Development

Write for InfoQ

Topics

Choose your language

InfoQ Homepage News Cross-Platform Mobile Toolkit "Flutter" Now Stable

Cross-Platform Mobile Toolkit "Flutter" Now Stable

Leia em Português

This item in japanese

Bookmarks

At its Flutter Live conference in London, Google launched the first stable release of Flutter, a Dart-based mobile development platform aiming to make it possible to write apps that share a single code base across iOS and Android with a native UI. Additionally, Google has announced an experimental web-based implementation of Flutter's runtime which aims to bring Flutter apps to standard web browsers.

After nine months in beta, Flutter 1.0 focuses very much on stabilization and bug fixes, along with a few new features such as Dart 2.1, new UI widgets, and previews for "Add to App" and "Platform Views".

Dart 2.1 provides smaller code sizes, faster type checking, and better diagnostics. According to Google, Dart 2.1 reduces minified output size by 17% and compilation time by 15%. Dart 2.1 also brings new language features, such as improved mixin support through a new mixin keyword for classes that can only be used as mixins; stricter type checking to prevent passing an int where a double is expected; new HTTP status codes; and more.

Add to app is Google's way of enabling progressive porting an existing app to Flutter. Still in preview, Add to app relies on the coexistence, in any Flutter app, of the Flutter runtime along with a native iOS or Android container. It consists of a growing number of templates that you can use with the flutter create command. This will create a library you can link into your existing app to provide an Activity or a ViewController which you can use from Java/ObjC-Swift code. By doing this, developers can easily add new features to their apps and/or re-implement existing features using Flutter.

Platform views can be seen as the dual of Add to app. Indeed, they enable the inclusion of an Android or iOS UI control into a Flutter app. This is made possible by two new widgets, AndroidView and UiKitView. Examples of useful applications of Platform views is the creation of plugins to wrap native platform controls such as Google Maps, WebView, etc. Significantly, since Platform views plugins are based on a Flutter widget, the native controls can naturally coexist with Flutter UI controls. Similarly to Add to app, Platform views is still considered of preview quality.

As mentioned, Google has also announced Hummingbird, a web-based experimental implementation of the Flutter runtime aiming to bring Flutter apps to the browser. Hummingbird leverages Dart capability to compile to JavaScript in addition to native ARM. While not changing Flutter's main focus on mobile, Hummingbird is one piece of Flutter's broader strategy to reach more platforms, including Windows, macOS, and Linux, which are targeted by another experimental project, Flutter Desktop Embedding.

Flutter 1.0 can be downloaded from Flutter website.

Rate this Article

Adoption
Style

BT