Google launches Flutter 2 for cross-platform app development
Mobile developers can now use the same codebase across iOS, Android, desktop, web, and smart devices
Google has upgraded its Flutter toolkit to allow mobile developers to seamlessly port native apps across a breadth of operating systems and web browsers, as well as devices such as TVs, cars, and smart home appliances.
Flutter, an open source software development kit (SDK) launched by Google in December 2018, allows developers to build mobile apps across both Android and iOS devices from a single codebase using the Dart language.
The next generation, dubbed Flutter 2, is a logical extension of this principle, with developers able to programme native apps across not just Android and iOS but also Windows, macOS, and Linux systems too. This is alongside web-based experiences across Chrome, Firefox, Safari, and Edge, as well as the operating systems powering IoT and smart devices.
“Our goal is to fundamentally shift how developers think about building apps, starting not with the platform you’re targeting but rather with the experience you want to create,” Google said in its Developer blog.
“In Flutter 2, released today, we’ve broadened Flutter from a mobile framework to a portable framework, unleashing your apps to run on a wide variety of different platforms with little or no change.”
Developing for Android devices with Android Studio, an integrated development environment (IDE), differs from developing with Flutter, in that it’s a Java-incorporated development workbench for creators to develop and debug their source code for one platform.
Using Android Studio means developers can’t build apps native to iOS as well as Android – and must jump through hoops to convert their codebase to be compatible with iPhones, or rewrite them from scratch.
Flutter, by contrast, was launched with native cross-platform development in mind, with app creators able to build applications for both iOS and Android using a single codebase. Features such as platform APIs, third-party SDKs and reusable user interface (UI) blocks lend themselves to this aim.
Google also touts Flutter as allowing you to build aesthetically-pleasing apps at-pace, in addition to making changes as your app’s running in real-time with the ‘hot reload’ feature. The ecosystem of Flutter-developed apps includes roughly 150,000 services including apps such as WeChat and Yandex Go.
Google Pay even switched to Flutter in September last year to achieve improvements in productivity and quality. By unifying the iOS and Android codebases, the development team removed roughly 500,000 lines of code. There’s also been a reported increase in the efficiency for engineers, with a reduction in work needed around releases such as security reviews and experimentation, given two codebases have been contracted to one.
Desktop support was added to an earlier alpha release of Flutter, but this has just been moved into the toolkit’s ‘stable’ channel, meaning it’s now generally available.
To make it happen, Google partnered with Canonical, the company that publishes Ubuntu, with the organisation’s engineers contributing code to support development and deployment on Linux installations.
Go further with mobile marketing
Easy steps to get your mobile strategy up-to-speedDownload now
Google has also expanded its partnership with Microsoft, with the Windows developer releasing contributions to the Flutter engine to support foldable Android devices, including new design patterns and functionality.
With Flutter 2, app developers will also find added support for the web with a focus on progressive web apps (PWAs) as well as single-page apps (SPAs) and bringing existing Flutter mobile apps to the web with shared code.
Finally, a partnership with Toyota paves the way for writing in-vehicle software using Flutter, with the car manufacturer using Flutter’s embedder API to tailor Flutter for the unique needs of its vehicles.
Join the 90% of enterprises accelerating to the cloud
Business transformation through digital modernisationFree Download
Delivering on demand: Momentum builds toward flexible IT
A modern digital workplace strategyFree download
Modernise the workforce experience
Actionable insights and an optimised experience for both IT and end usersFree Download
The digital workplace roadmap
A leader's guide to strategy and successFree Download