Google has released the current version 2 of its UI framework Flutter, which is written in the Dart programming language.
The aim of Flutter is to “fundamentally change the way developers think when creating apps.” It should no longer start with thoughts about the platform on which the app should run but simply with which user experience the app should implement. This is to be achieved with complete platform independence, which the team is getting a little closer to with the now stable web support as part of Flutter 2.
Google first announced the expansion of Flutter beyond iOS and Android at its in-house exhibition I/O in May 2019. The now stable web support, with Flutter 2, Google is primarily concentrating on three application scenarios — use in progressive web apps (PWAs), single-page applications, and the option of using existing flutter apps in the mobile systems in the web browser.
In addition to the classic HTML renderer, which displays the Flutter web app as a DOM tree with CSS and canvas elements, Flutter now also has a renderer based on Canvaskit. The latter is based on the Skia graphics library and uses WebAssembly and WebGL. This is primarily intended to accelerate graphics-intensive applications. More details about the web support in Flutter 2 can be found in a very detailed blog post.
In addition to web support, Flutter apps also run natively on desktop systems such as Linux or Windows. This desktop support is already included in the stable release but still under an early release flag, as stated in the announcement. The team calls this release a kind of beta snapshot.
In addition, Flutter is now using version 2.12 of Dart, which offers so-called zero safety. This means that the type system already checks whether values should be zero or not, which is intended to prevent zero errors and thus also crashes of Flutter apps.