README.md 2.19 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27
# Templates for Flutter Module

## common

Written to root of Flutter module.

Adds Dart project files including `pubspec.yaml`.

## android

#### library

Written to the `.android/` hidden folder.

Contents wraps Flutter/Dart code as a Gradle project that defines an
Android library.

Executing `./gradlew flutter:assembleDebug` in that folder produces
a `.aar` archive.

Android host apps can set up a dependency to this project to consume
Flutter views.

#### gradle

Written to `.android/` or `android/`.

28
Mixin for adding Gradle boilerplate to Android projects.
29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59

#### host_app_common

Written to either `.android/` or `android/`.

Contents define a single-Activity, single-View Android host app
with a dependency on the `.android/Flutter` library.

Executing `./gradlew app:assembleDebug` in the target folder produces
an `.apk` archive.

Used with either `android_host_ephemeral` or `android_host_materialized`.

#### host_app_ephemeral

Written to `.android/` on top of `android_host_common`.

Combined contents define an *ephemeral* (hidden, auto-generated,
under Flutter tooling control) Android host app with a dependency on the
`.android/Flutter` library.

#### host_app_materialized

Written to `android/` on top of `android_host_common`.

Combined contents define a *materialized* (visible, one-time generated,
under app author control) Android host app with a dependency on the
`.android/Flutter` library.

## ios

60 61 62
#### library

Written to the `.ios/Flutter` hidden folder.
63

64
Contents wraps Flutter/Dart code for consumption by an Xcode project.
65

66
iOS host apps can set up a dependency to this contents to consume
67
Flutter views.
68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87

#### host_app_ephemeral

Written to `.ios/` outside the `Flutter/` sub-folder.

Combined contents define an *ephemeral* (hidden, auto-generated,
under Flutter tooling control) iOS host app with a dependency on the
`.ios/Flutter` folder contents.

The host app does not make use of CocoaPods, and is therefore
suitable only when the Flutter part declares no plugin dependencies.

#### host_app_ephemeral_cocoapods

Written to `.ios/` on top of `host_app_ephemeral`.
 
Adds CocoaPods support.

Combined contents define an ephemeral host app suitable for when the
Flutter part declares plugin dependencies.