Flutter combat (1) What is Flutter?

Flutter

This is the first part of the Flutter combat series. First, I will introduce Flutter as a whole, aiming to give you a global perceptual understanding of Flutter. If you want to know more, you can go to [Flutter Chinese website](https://flutterchina.club/) to learn more. Follow-up tutorials will be released one after another. If you are interested in Flutter, please follow my blog.

What is Flutter?

Flutter is Google's mobile cross-platform UI framework that can quickly build high-quality native user interfaces on iOS and Android. Flutter works with existing code. All over the world, Flutter is being used by more and more developers and organizations, and Flutter is completely free and open source. To put it simply, Flutter is a mobile application SDK that includes frameworks, controls and tools. It can build both Android and iOS applications with a single set of code, and the performance can reach the same performance as native applications. For details, please refer to Introduction to Flutter .

What language is Flutter developed in?

Flutter uses Dart as the development framework and widget language. For details, please refer to Why Flutter chooses Dart language .

Is Dart language easy to learn?

If you have programming experience, especially know Java or Javascript, then you will find that Dart is very easy to learn. I only spent two hours to start coding with Dart happily. Flutter Chinese website has compiled a list of Dart language resources that can help you learn Dart quickly , I hope it will be useful to you.

What is the difference between Flutter and dynamic frameworks like React-Native and Weex?

The core of React-Native and Weex is developed through Javascript, and a Javascript interpreter is required for execution, and the UI is rendered through native controls. Flutter is different from most other frameworks for building mobile applications because Flutter neither uses WebView nor native controls of the operating system. Instead, Flutter uses its own high-performance rendering engine to draw widgets. Flutter is built using C, C++, Dart and Skia (2D rendering engine). On IOS, the C/C++ code of the Flutter engine is compiled using LLVM, any Dart code is AOT compiled to native code, and the Flutter application runs using the native instruction set (no interpreter involved). Under Android, the C/C++ code of the Flutter engine is compiled with Android's NDK, any Dart code is AOT compiled into native code, and the Flutter application still runs using the native instruction set (no interpreter involved) . Therefore, Flutter can achieve the same performance as native applications.

At the same time, Flutter provides a set of its own widgets), which are managed and rendered by Flutter's framework and engine. You can browse the catalog of Flutter widgets . The reason why native controls are not applicable is because Flutter expects the final result to be of higher quality. If Flutter uses native system widgets, the quality and performance of Flutter applications will be limited by the quality of these widgets themselves. For example, in Android, there is a set of hard-coded gestures and fixed rules for gesture conflict disambiguation over them. In Flutter, you can write your own gesture recognizer, which is a first-level participant in the gesture system . Additionally, two gadgets written by different people coordinate gesture conflict disambiguation.

Does Flutter support "hot reload" like webpack or Android "instant run"?

Yes, Flutter supports Hot Reload, which works by injecting updated source code files into a running Dart VM (Virtual Machine). This includes not only adding new classes, but also adding methods and fields to existing classes, and changing existing functions. See Flutter Hot Reload for details .

What experience is necessary for a programmer/developer to use Flutter?

Flutter is easy to get started with for programmers familiar with object-oriented concepts (classes, methods, variables, etc.) and imperative programming concepts (loops, conditionals, etc.). Learn and use Flutter without prior mobile development experience. We've seen people with little programming experience learn and use Flutter for prototyping and application development.

Can I use Flutter in my existing native app?

Yes, you can embed Flutter in your existing Android or iOS app. For details, see Using Flutter in Native Apps .

Does Flutter support file reading and initiating network requests?

support! For details, please refer to:

  1. Flutter file manipulation .
  2. Flutter initiates an Http request .

Where can I get Flutter learning resources?

You can go to the Google Flutter official website, but now you can also visit the Flutter Chinese website . The Flutter Chinese website provides official document translations and some other cases and resources. You can also go to the Flutter project homepage on Github to view the latest developments and suggestions. issue.

Reference documents for this article: Flutter Chinese Network-Flutter FAQ .

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=324647731&siteId=291194637