All Projects → russhwolf → To Do

russhwolf / To Do

Licence: apache-2.0
A Kotlin Multiplatform to-do list app with SwiftUI and Compose UI frontends

Programming Languages

kotlin
9241 projects

Labels

Projects that are alternatives of or similar to To Do

Open source demos
A collection of demos showcasing automated feature engineering and machine learning in diverse use cases
Stars: ✭ 391 (+272.38%)
Mutual labels:  compose
Docker Compose Elasticsearch Kibana
Docker Compose for Elasticsearch and Kibana
Stars: ✭ 584 (+456.19%)
Mutual labels:  compose
Opencompose
OpenCompose - A higher level abstraction for Kubernetes Resource
Stars: ✭ 66 (-37.14%)
Mutual labels:  compose
Playandroid
🔥🔥🔥 Kotlin + MVVM + LCE版玩安卓,暗黑模式、横竖屏、无网、弱网、无数据、加载失败等等各种情况,协程、Room、Hilt、DataStore、LiveData、Retrofit、屏幕适配、本地缓存、多语言切换、多 lib,你想要的我都有!!!
Stars: ✭ 414 (+294.29%)
Mutual labels:  compose
Schm
Composable schemas for JavaScript and Node.js
Stars: ✭ 498 (+374.29%)
Mutual labels:  compose
Compose Spec
The Compose specification
Stars: ✭ 603 (+474.29%)
Mutual labels:  compose
Disneycompose
🧸 A demo Disney app using Jetpack Compose and Hilt based on modern Android tech-stacks and MVVM architecture.
Stars: ✭ 368 (+250.48%)
Mutual labels:  compose
Learn Jetpack Compose By Example
🚀 This project contains various examples that show how you would do things the "Jetpack Compose" way
Stars: ✭ 1,319 (+1156.19%)
Mutual labels:  compose
Android Iconics
Android-Iconics - Use any icon font, or vector (.svg) as drawable in your application.
Stars: ✭ 4,916 (+4581.9%)
Mutual labels:  compose
Jetpack Compose Playground
Community-driven collection of Jetpack Compose example code and tutorials 🚀 https://foso.github.io/compose
Stars: ✭ 969 (+822.86%)
Mutual labels:  compose
Wordpress Nginx Docker Compose
Run WordPress with nginx using Docker Compose.
Stars: ✭ 460 (+338.1%)
Mutual labels:  compose
Radiography
Text-ray goggles for your Android UI.
Stars: ✭ 482 (+359.05%)
Mutual labels:  compose
Rooks
Essential hooks ⚓ to super charge your components!
Stars: ✭ 889 (+746.67%)
Mutual labels:  compose
Compose Jb
Jetpack Compose for Desktop and Web, a modern UI framework for Kotlin that makes building performant and beautiful user interfaces easy and enjoyable.
Stars: ✭ 7,562 (+7101.9%)
Mutual labels:  compose
Plasma
An Android Application written using latest Android Jetpack components and best practices, which displays trending movies/TV shows and cast, user can search movies and TV shows and also add them to watchlist.
Stars: ✭ 67 (-36.19%)
Mutual labels:  compose
Jetpack Compose Whatsapp Clone
An example project to demonstrate how to build WhatsApp using Jetpack Compose.
Stars: ✭ 386 (+267.62%)
Mutual labels:  compose
Hue
Open source SQL Query Assistant service for Databases/Warehouses
Stars: ✭ 351 (+234.29%)
Mutual labels:  compose
Androidcomposesamples
An Android app which provides examples for Android Jetpack Compose
Stars: ✭ 105 (+0%)
Mutual labels:  compose
Docker Series
Docker Series about containerizing ASP.NET Core app with MySQL..
Stars: ✭ 88 (-16.19%)
Mutual labels:  compose
Cloud Integration Beta
Docker CLI with ACI integration (beta)
Stars: ✭ 29 (-72.38%)
Mutual labels:  compose

To-Do

A Kotlin Multiplatform to-do list app with SwiftUI and Compose UI frontends

🎶
Making a list
Checking it twice
Gonna try out declarative UIs
🎵

Android Image iOS Image

Disclaimer

I'm just starting to learn my way around both Compose and SwiftUI so the code here can probably be improved on.

Shared code

The core logic in the shared module is implemented via SqlDelight in ToDo.sq. This is exposed in a Kotlin API by ToDoRepository.

In addition to pure common code, there are some iOS-specific helpers. Since suspend functions and Flows aren't available to Swift, FlowAdapter is a slightly modified version of the pattern I presented in my Working with Kotlin Coroutines and RxSwift blog post. A wrapper class ToDoRepositoryIos then exposes iOS-friendly versions of ToDoRespository's API.

Unit tests verify the happy path for both repository classes, making use of the Turbine library for testing Flows. Not a whole lot new there if you're used to testing KMP code, but they're there to look at nonetheless.

Android code

The Android app in the androidApp modules is a single activity ToDoActivity which injects a ToDoRepository into composable views defined in ToDoComposables.kt. There is a fully interactable preview function ToDoListPreview() which exercises the UI without any dependence on the shared code by manually wiring in-memory state

iOS code

The iOS app in the iosApp directory consumes the repository in SceneDelegate.swift, and renders it via SwiftUI views defined in ToDoViews.swift. There is a fully interactable preview view defined in ToDoList_Previews which exercises the UI without any dependence on the shared code by manually wiring in-memory state.

The SwiftUI code makes use of some Combine helpers defined in CombineAdapters.swift in order to translate FlowAdapter to a Published value that SwiftUI can subscribe to. It also converts the Kotlin ToDo class to a Swift ToDo struct via utilities in ToDo.swift. This better matches typical Swift development practices, and it means that the SwiftUI views have no direct dependence on the Kotlin code, which apparently helps the preview work better.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].