Danesz / flutter-compose-swiftui-sample

Sample Flutter project using Jetpack Compose and SwiftUI native views

Home Page:https://danieldallos.com

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Binding Jetpack Compose (Android) and SwiftUI (iOS and MacOS) views in Flutter

A sample Flutter project using Jetpack Compose and SwiftUI native views

What is this?

Flutter offers a wide range of customizable widgets and rich design capabilities, allowing you to create complex and visually appealing user interfaces. Custom widgets can be built using the same tools and techniques as standard ones.

Flutter also provides access to native device features and APIs through platform channels, allowing you to integrate platform-specific functionality seamlessly into your app.

Flutter on Android easily integrates with the default Android View classes through platform views.

The same is true on iOS (and MacOS). Integrating with UIKit is straightforward too.

But

Nowadays new UI frameworks are on the rise.

"Jetpack Compose is Android’s recommended modern toolkit for building native UI. It simplifies and accelerates UI development on Android. Quickly bring your app to life with less code, powerful tools, and intuitive Kotlin APIs."

"SwiftUI helps you build great-looking apps across all Apple platforms with the power of Swift — and surprisingly little code. You can bring even better experiences to everyone, on any Apple device, using just one set of tools and APIs."

Using these new frameworks on native platforms is effortless and well-documented.

It is possible to combine them with the "old" UI elements and you can find documentations about them.

However, if you start with Flutter and you have less native development experience, finding the correct information could be a bit tricky.

This project aims to help with this, showcasing the basic UI binding technique on Android with Jetpack Compose; and on iOS and macOS with SwiftUI.

IN PROGRESS: currently the code has documentation and links to relevant websites, but you can expect a write-up about the topic soon.

How to start?

This is a generic Flutter project with support for iOS, Android, and macOS.

Please follow the official Getting Started guide below.

TLDR;

  1. Download the Flutter
  2. Checkout this project
  3. Open the root folder of this project in Android Studio
  4. Compile and run the project for specific targets

Flutter Getting Started

This project is a starting point for a Flutter application.

A few resources to get you started if this is your first Flutter project:

For help getting started with Flutter development, view the online documentation, which offers tutorials, samples, guidance on mobile development, and a full API reference.

About

Sample Flutter project using Jetpack Compose and SwiftUI native views

https://danieldallos.com

License:MIT License


Languages

Language:Dart 44.4%Language:Swift 35.2%Language:Kotlin 20.2%Language:Objective-C 0.2%