Flutter is a new mobile application development environment that arrived on the scene in early 2019 and has attracted a lot of attention. Voximplant is really excited about Flutter because it promises to shorten time to market for new apps, reduce testing and QA cycles, improve application performance, and deliver beautiful user experiences. No matter what type of application you’re developing, Flutter deserves consideration, including apps that embed real-time communications.
In this introductory article, we’ll explore the many features and benefits of Flutter and its programming language, Dart. We’ll describe the Flutter support we’ve added to our own CPaaS product line.
Flutter Background
Google describes Flutter as a portable UI toolkit. It can also be described as an SDK because it includes a programming language with development tools, modern react-style framework, APIs, command-line tools that produce machine code for iOS and Android, and customizable widgets.
Flutter is built by Google and available as free open source code. Similar to hybrid development frameworks, it enables developers to leverage a single code base to deliver apps for both iOS and Android mobile platforms. But, there is more: Google has added web and desktop support to Flutter, too. This will further boost ROI for developers.
Skyrocketing Flutter popularity
Using Github stars as a measure, Flutter has become more popular than React Native more quickly. Flutter has gained 98.9K Github stars in the 18 months since its 1.0 release, as compared to 89.6K for React Native over 5 years. Flutter is listed among the top 20 most active repositories on GitHub and Google says over 500,000 developers use it, monthly.
Certainly, Flutter lags React Native in the number of apps deployed. But with over 90,000 apps published in the Google Play Store, Flutter’s momentum is building. Notable design wins include the Xianyu commerce app by Alibaba, NuBank banking app, Google Ads (of course), and a Hamilton app for fans of the musical.
Google’s Flutter strategy
Google created Flutter is to help expand the number of apps available for Android. Even though hybrid frameworks have enabled developers to leverage a single code base for both iOS and Android, which is a big advancement over separate native Swift and Java apps for each platform, these development environments present some limitations that have slowed the pace of Android support. Flutter reduces multiple friction points with:
- Automatic support for the many Android devices and screen sizes available in Google’s OEM licensing model
- High-quality native-like UI support for iOS and Android platforms
- A full complement of customizable widgets that eliminate the complexities of using third-party libraries
Google is investing heavily to add features and support for additional platforms. Version 1.0 was released in December 2018 and the web preview version 1.50 was added in May 2019. Stability, features, and performance have consistently improved to produce a mature development environment.
Flutter Flexes Big Muscles
Flutter comes packed with a rich feature set that eliminates dependencies on third-party libraries and code that can slow down development with hybrid frameworks. Here are the features we’re most excited about:
- Performance - Flutter is fast because it has its own high-performance rendering engine and source code compiles directly to ARM and x86-64 machine code for iOS and Android
- Customizable widgets - deliver a beautifully native look and feel across Android and iOS platforms by conforming to their respective design languages (Material Design implements the Android language and Cupertino imitates the iOS design). You can easily implement buttons, sliders, switches, dialog boxes, tab bars, and loading spinners
- Hot reload - make changes to your applications on-the-fly and see the results in milliseconds. Quickly add features, fix bugs, and try out new ideas.
- Device API - for real-time communications developers, Flutter is similar to React Native with native APIs to access camera, microphone and other hardware
- Backward compatibility - Flutter apps run on older operating system versions and platforms with no tradeoffs or degradation.
Dart is the Flutter Programming Language
Developers will need to learn a new language when they move to Flutter. But, the learning curve isn’t very steep because Dart is a modern, class-based, object-oriented programming language. It will be familiar to anyone with Java or C# experience.
Like Java, Dart is a statically typed language that checks variables and flags script errors at compile time instead of run time. Dart code has the flexibility to run in multiple environments:
Web browsers - A source-to-source javascript compiler enables apps to run in mainstream web browsers.
Standalone - A Dart virtual machine enables the code to run in a command line interface environment with super fast performance
Ahead of time (AOT) compiled - Enables apps to run as native machine code
It includes the open-source Dart Editor with features that include code completion, refactoring, and inline warnings. Alternatively, developers can use Eclipse or IntelliJ. Dart also features the Pubs function, which enables developers to install and manage third party Dart libraries.
Like Flutter, Dart is developed by Google. It was named the fastest growing programming language in 2019 by Octoverse, outpacing Rust with 532% usage growth.
Many Flutter Benefits for App Developers
Even though developers may need to invest in learning how to use Flutter and Dart before they are productive, we think there are a lot of benefits that make the investment worthwhile.
Fast time to market - A bunch of powerful features accelerate time-to-market for new apps, including common codebase for iOS, Android and web apps, widgets that eliminate third party library complexity, hot reload for fast prototyping and debugging
Reduce costs - Developers report 50% fewer automated tests were needed because the same tests run on both platforms, reducing demand on QA teams
Attractive UI - Flexible design components and interactivity elements give developers powerful tools to deliver stunningly attractive user experiences with a native-like look and feel on iOS and Android
Consistent operation - Because they share the same codebase, apps look and behave similarly across iOS and Android
High performance - Smooth scrolling without cutting because widgets are rendered and managed by Flutter’s high-performance graphics engine
Older device support - New apps work seamlessly with older iOS and Android devices with identical look and feel no matter the screen size
Of course, Flutter is supported by accessible, straight-forward documentation, knowledgeable Google staff and contributions from the open source community. This makes it easy for developers to get started with Flutter.
Voximplant embraces Flutter for real time communications
We believe Flutter will be a wildly successful environment for developing all types of applications, including those that embed voice and video communications. As a result, we released one of the first complete Flutter SDKs for calling in September 2019 and have been steadily enhancing it since.
The Voximplant SDK provides libraries you can use to build peer-to-peer calling and multiparty conferencing applications with support for voice or video. Developers can easily control media input (camera, microphone) and output devices. The SDK also provides libraries for IP messaging applications.
Consider Flutter for your next project
Completely new development environments don’t come along very often. When they do, it’s worthwhile for software developers to step back and decide whether to adopt them. This is especially true when Google throws its considerable weight behind a new technology, as it has with Flutter.
As Flutter momentum continues to grow, we anticipate many of you will want to use it to build your communications apps. That’s why we’ve added support to our CPaaS product line.