text
stringlengths 1
474
|
---|
to be more brand-driven and unified across platforms.
|
This implies a strong motivation to share layout and UI
|
code across iOS and Android.The brand identity and customization of the app’s
|
aesthetic design is now becoming more important than
|
strictly adhering to traditional platform aesthetics.
|
For example, app designs often require custom fonts, colors,
|
shapes, motion, and more in order to clearly convey their
|
brand identity.We also see common layout patterns deployed across
|
iOS and Android. For example, the “bottom nav bar”
|
pattern can now be naturally found across iOS and Android.
|
There seems to be a convergence of design ideas
|
across mobile platforms.<topic_end>
|
<topic_start>
|
Can I interop with my mobile platform’s default programming language?
|
Yes, Flutter supports calling into the platform,
|
including integrating with Java or Kotlin code on Android,
|
and ObjectiveC or Swift code on iOS.
|
This is enabled by a flexible message passing style
|
where a Flutter app might send and receive messages
|
to the mobile platform using a BasicMessageChannel.Learn more about accessing platform and third-party services
|
in Flutter with platform channels.Here is an example project that shows how to use a
|
platform channel to access battery state information on
|
iOS and Android.<topic_end>
|
<topic_start>
|
Does Flutter come with a reflection / mirrors system?
|
No. Dart includes dart:mirrors,
|
which provides type reflection. But since
|
Flutter apps are pre-compiled for production,
|
and binary size is always a concern with mobile apps,
|
this library is unavailable for Flutter apps.Using static analysis we can strip out anything that isn’t
|
used (“tree shaking”). If you import a huge Dart library
|
but only use a self-contained two-line method,
|
then you only pay the cost of the two-line method,
|
even if that Dart library itself imports dozens and
|
dozens of other libraries. This guarantee is only secure
|
if Dart can identify the code path at compile time.
|
To date, we’ve found other approaches for specific needs
|
that offer a better trade-off, such as code generation.<topic_end>
|
<topic_start>
|
How do I do internationalization (i18n), localization (l10n), and accessibility (a11y) in Flutter?
|
Learn more about i18n and l10n in the
|
internationalization tutorial.Learn more about a11y in the
|
accessibility documentation.<topic_end>
|
<topic_start>
|
How do I write parallel and/or concurrent apps for Flutter?
|
Flutter supports isolates. Isolates are separate heaps in
|
Flutter’s VM, and they are able to run in parallel
|
(usually implemented as separate threads). Isolates
|
communicate by sending and receiving asynchronous messages.Check out an example of using isolates with Flutter.<topic_end>
|
<topic_start>
|
Can I run Dart code in the background of a Flutter app?
|
Yes, you can run Dart code in a background process on both
|
iOS and Android. For more information, see the free Medium article
|
Executing Dart in the Background with Flutter Plugins and Geofencing.<topic_end>
|
<topic_start>
|
Can I use JSON/XML/protobuffers (and so on) with Flutter?
|
Absolutely. There are libraries on
|
pub.dev for JSON, XML, protobufs,
|
and many other utilities and formats.For a detailed writeup on using JSON with Flutter,
|
check out the JSON tutorial.<topic_end>
|
<topic_start>
|
Can I build 3D (OpenGL) apps with Flutter?
|
Today we don’t support 3D using OpenGL ES or similar.
|
We have long-term plans to expose an optimized 3D API,
|
but right now we’re focused on 2D.<topic_end>
|
<topic_start>
|
Why is my APK or IPA so big?
|
Usually, assets including images, sound files, fonts, and so on,
|
are the bulk of an APK or IPA. Various tools in the
|
Android and iOS ecosystems can help you understand
|
what’s inside of your APK or IPA.Also, be sure to create a release build
|
of your APK or IPA with the Flutter tools.
|
A release build is usually much smaller
|
than a debug build.Learn more about creating a
|
release build of your Android app,
|
and creating a release build of your iOS app.
|
Also, check out Measuring your app’s size.<topic_end>
|
<topic_start>
|
Do Flutter apps run on Chromebooks?
|
We have seen Flutter apps run on some Chromebooks.
|
We are tracking issues related to running Flutter on
|
Chromebooks.<topic_end>
|
<topic_start>
|
Is Flutter ABI compatible?
|
Flutter and Dart don’t offer application binary interface (ABI)
|
compatibility. Offering ABI compatibility is not a current
|
goal for Flutter or Dart.<topic_end>
|
<topic_start>
|
Framework
|
<topic_end>
|
<topic_start>
|
Why is the build() method on State, rather than StatefulWidget?
|
Putting a Widget build(BuildContext context) method on State
|
rather putting a Widget build(BuildContext context, State state)
|
method on StatefulWidget gives developers more flexibility when
|
subclassing StatefulWidget. You can read a more
|
detailed discussion on the API docs for State.build.<topic_end>
|
<topic_start>
|
Where is Flutter’s markup language? Why doesn’t Flutter have a markup syntax?
|
Flutter UIs are built with an imperative, object-oriented
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.