Google released the new Dart 2.6 update with Flutter 1.9 version

Tram Ho

Summary of new news:

  • Native dart2native and Dart compiler
  • Dart allows you to build the application with the dart2native command
  • Dart allows interaction with C code through dart: ffi
  • Dart helps build some services with dart2native
  • Flutter 1.9 update can support iOS 13 with macOS Catalina. It also comes with new widgets.
  • Flutter is designed for the Web
  • Flutter is supported for iOS 13 and macOS Catalina

Google recently released Dart 2.6 and Flutter 1.9 updates so it can support iOS 13 and macOS Catalina.

Flutter 1.9 will now allow developers to create mobile, web and desktop applications from one and the same code base.

Details about all these updates so we understand it better.

Dart 2.6

This update Google focused on the dart2native , which is an extension of their existing compiler, with the ability to compile Dart programs into standalone executables containing compiled machine code. With dart2native , you can create tools using the command line on macOS, Windows or Linux using Dart.

Native dart2native and Native compiler

Dart has supported compiling AOT (ahead of time) for native code for several years and therefore, Dart Native is a fairly mature technology. However, previously we only exposed this ability on iOS and Android mobile devices , through Flutter.

With dart2native , we have expanded our native compilation support to support traditional desktop operating systems running macOS, Windows and Linux.

If you have used dart2aot before, up to 2.6 you will use dart2native . It provides a set of dart2aot functions.

Dart allows you to build the application with the dart2native command

The dart2native compiler is a great option for building and deploying Dart-based applications using the command line. These applications often use libraries such as dart:io (basic I / O), package: http (networking), and package: args (argument parsing). Let's review the basic demo of compiling a Hello World application into an executable file:

Source code hello.dart:

Compile hello.dart into hello file to run:

Run hello:

Many developers have used dart2native to create some command-line tools such as: SASS , linkchecker tool.

Dart allows interaction with C code through dart: ffi

Native applications often need to access native functionality from the operating system. These system APIs are often displayed in C and Dart-based libraries that support interoperability with these libraries through dart: ffi , their new mechanism for C interop , which they introduced in preview in Dart 2.5. The dart2native compiler is compatible with dart: ffi , so you can create and compile Dart applications through using it.

Dart helps build some services with dart2native

Another potential application of the dart2native compiler is for small services – for example, the frontend app support service is written in Flutter. In recent years, an increasing trend has been the use of services that run on serverless computing . These are fully scaled managed services, offering the potential to greatly reduce costs because they are only billed when they actually run. Google Cloud provides serverless computing through Cloud Run .

Flutter 1.9

The newly released version of Flutter 1.9 provides support for running macOS Catalina and iOS 13 with improvements such as new tools, new material widgets and new features in the Dart language.

Google claims Flutter 1.9 is the biggest update to date with over 1,500 Pull Requests from over 100 contributors.

In fact, the new Flutter 1.9 provides support for 24 other languages: South African, Albanian, Amharic, Assamese, Irish, Basque, Belorussian, Bengali, Burmese, Gujarati, Icelandic, Georgian, Kannada, Oriya, Punjabi, Sinhalese, Telugu, Uzbek and Zulu.

Flutter is designed for the Web

The first technical review for Flutter for Web was the release in Google's I / O conference in 2019. The company has now integrated the Flutter web repository with the main Flutter repo, meaning developers will be able to Write code for mobile, web and desktop with the same code base.

Flutter creates a process to run the web through a web file // index.html . Later, the file allows you to use the Flutter CLI tool or IDE plugins to run and edit Flutter applications on the web.

However, Google also said that support for web output is still ongoing.

Flutter is supported for iOS 13 and macOS Catalina

Flutter supports iOS13 and macOS as a result of Google wanting to make Flutter work with Xcode 11. Flutter also supports the new Xcode build system and 64 bit support throughout the tool chain and simplifies the above. each platform.

Flutter 1.9 also has a draggable toolbar implementation in iOS 13, with both right-click and drag-to-support while supporting vibration feedback.

In addition, Flutter 1.9 comes with some new utilities, using Google's Material Design. Icon and text gadgets combine to form a set of buttons. The new ColorFiltered utility helps you to color your widgets and similarly, you can color an image with the help of different algorithms.

Share the news now

Source : CafeDev