Open1

Build Native Mobile Apps with Flutter #1

Tatsushi KiryuTatsushi Kiryu
  • a view is built as an immutable tree of widgets.
  • Widgets are foundation of Flutter apps.

https://classroom.udacity.com/courses/ud905/lessons/92a39eec-0c04-4d98-b47f-c884b9cd5a3b/concepts/bb4c8ab6-ee61-4f99-bcf8-7f6d9c7d81f0

  • The framework creates a diff to deterlmin the minimal changes needed to update the render tree.
  • We don't need to bridge the UI rendering code to the native platform.
  • Layout and rendering calls happen much more frequently than platform-specific calls.
  • By doing all the rendering work on the app side, Flutter an quickly render and re-render your widget tree allowing rich motion and smooth scrolling.
  • This rendering engine is built in Skia, a 2D graphics rendering library and Dart, it displays widgets for both iOS and Android devices. The iOS and ANdroid platforms just have to provide a canvas for us to place our widgets on and rendering engine inside. This is where it's useful to have ahead of time compilation to native code.
    • Ahead-of-time
      • The code your app uses is compiled directly to native ARM code, leading to fast startup and predictable performance.
    • As long as someone and it could be you, has written their required device plug-ins for your app, such as camera and Wi-Fi and as long as your platform returns to canvas, your Flutter app can be compiled down to run on your target platform of choice.
  • RenderObject
  • RenderBox