Today is the Flutter Interact event in New York City, where Google is unveiling the latest advancements for their app development software Flutter. This year, Flutter’s focus is to expand on Google’s company-wide push for “ambient computing” by supporting more platforms like macOS.
Flutter and ambient computing
At the Made by Google event this past October, where the Pixel 4 was officially unveiled, Googlers showed how each device being announced furthers their ambitions for “ambient computing.” In Google’s “ambient computing” vision, people no longer need to think about which of their many devices is the right one for the job, but are perfectly capable of any task from whatever gadget may be handy.
To make that vision possible, developers need to create seamless and consistent experiences across the variety of devices we use every day. Until recently, this was a monumental effort, as developers needed to learn a new programming language or a new SDK for each individual platform.
With the Flutter SDK, Google has finally changed that, enabling developers to use one shared codebase to create fast, consistent, native apps for Android, iOS, smart displays, Fuchsia, and the Web.
Flutter 1.12 |
Flutter for macOS alpha
The next frontier for Flutter is the desktop computer, with macOS being the first target Google has in mind. Developers have long been able to use their Mac machines to create Android and iOS apps with Flutter, and starting with today’s Flutter 1.12 release, it’s now possible to create apps directly for macOS.
To prepare for desktop platforms like macOS, the Flutter team has been hard at work making their built-in set of UI widgets desktop-friendly with things like keyboard navigation support. Flutter 1.12 also includes the ability to change your app’s “visual density,” as defined in the Material Design guidelines, to better accommodate the screen size differences between mobile and desktop.
For now, Flutter’s macOS app support is still considered to be in alpha, and requires developers to be on either the dev or master version of the Flutter SDK.
Flutter for Web Beta
Last year at Flutter Live, the team showed off a technical preview of making Flutter apps for the web, codenamed Hummingbird. Since then, work has continued non-stop to making Flutter for Web as stable of an experience as it can be. As part of Flutter 1.12, Flutter for Web is now officially in beta.
While that still sounds like the tech is still in its early days, remember that Google called Flutter “production-ready” after its third beta release. To get an understanding of how well Flutter for Web works today, look no further than the recently updated DartPad web app which lets you develop and try Flutter for Web apps right from your browser.
iOS 13 Dark Mode
For those who prefer to stay on stable builds, the biggest improvement coming with Flutter 1.12 is complete support for dark mode in iOS 13. Earlier this year, Flutter picked up proper support for automatically toggling to dark mode on Android 10, requiring very little effort on the developer’s part to enable, if they use Flutter’s stock Material Design widgets.
As of today’s release, all of the iOS-like widgets, called “Cupertino,” are now similarly available in a dark theme that can be automatically enabled based on a device’s dark mode settings.
Add-to-app
The other major feature of Flutter 1.12 is official, stable support for adding Flutter to any existing iOS or Android app. This is particularly useful for migrating your app to Flutter one step at a time, rather than needing to start from scratch. Android developers can even take advantage of the newly added “Flutter Module” option in Android Studio’s New Module view to swiftly add Flutter to their Android project.
Dart 2.7
The Dart programming language is the foundation of Flutter, and is also receiving an update today to version 2.7. The release brings stable support for “extension methods” — first previewed in Dart 2.6 — that let developers create convenient new functionality and tack it on to any existing class.
https://gist.github.com/RedBrogdon/ce732b859c758e04ee74e4e40b517ced
Dart 2.7 also includes an early preview of the language’s new “null safety” features that help developers catch potential mistakes related to a variable being unexpectedly null. By marking in the code which variables could be null, Dart’s tools can make sure your code is prepared for those times when they are null. To test these null safety features out without making major adjustments to your own code, Google has launched a special version of DartPad with null safety enabled.
Developers can download Flutter 1.12 from the official website now or update by running flutter upgrade. Dart 2.7 is built into today’s Flutter 1.12 release and is also available as a standalone download. Or, if you haven’t yet tried creating a Flutter or Dart app, it’s never been easier, thanks to the recent addition of Flutter support in Google’s online developer playground DartPad.
FTC: We use income earning auto affiliate links. More.
Comments