Testing! :-D · Difficulty #5421 · streetcomplete/StreetComplete · GitHub


This ticket is one thing just like the grasp ticket to coordinate growth on an iOS port of StreetComplete. It replaces #1892 which additionally included a number of dialogue and analysis / remark work.

TLDR: Have a take a look at the Project Board for a listing of duties. Contributions are welcome!

Also take a look on the Slides from SotM Europe 2024 talk (I added speaker notes to make this comprehensible when flipping via).

The code base of this app is written in 100% Kotlin, a contemporary programming language that’s fairly just like Swift. Kotlin code may be transpiled to JavaScript and likewise to machine code, similar to Swift. Furthermore, many dependencies of this app by now are pure Kotlin libraries.

An iOS model of this app therefore may be completed with Kotlin Multiplatform.

The UI code may be shared utilizing Compose Multiplatform, which is at the moment in alpha beta for iOS. It is a fork/extension of Jetpack Compose with largely the identical API. Jetpack Compose is a reactive UI framework during which builders outline the UI fully in code (related thought as SwiftUI, Flutter, …). We’ll need to re-create your complete UI (incrementally) in Compose, although.

This will maintain the quantity of code that must be platform dependent (Android / iOS) to a minimal.

This strategy has the massive benefit over others in that additional upkeep of this mission won’t improve considerably, as there’ll proceed to be only one code base. In comparability to utilizing the framework Flutter for multiplatform (as utilized by Every Door), it permits us to largely not contact the Kotlin codebase. When utilizing Flutter, we would have to rewrite all of it in Dart.

  • Separate all platform particular code from software logic. Replace Android/Java dependencies for software logic with Kotlin multiplatform dependencies

  • Incrementally migrate the UI code to Compose Multiplatform:

    1. Separate knowledge entry and UI state code from pure UI code (use view fashions: Use ViewModels #5070 )

    2. Migrate the UI code that at the moment makes use of Android XML layouts to Android Jetpack Compose. This may be completed incrementally when completed bottom-up (see migration strategy guide)

    3. Then, migrate from Jetpack Compose to Compose Multiplatform. This is a small step in contrast with the primary one.

This part will probably be up to date constantly.

The steps mandatory are described intimately in a Kanban-style Project Board. (Some duties haven’t been created but as a result of they 100% depend upon different duties accomplished first and a few analysis). Unless acknowledged in any other case, they’re explicitly up for the taking by individuals who learn this and (I hope 😊) need to contribute to the event in direction of an iOS port. If you want to implement one of many duties described, remark in that ticket.

We very roughly estimated a while in the past that growing a full port to iOS would take one man-year of labor. So, the scope of this stays very giant. We will solely realistically obtain it along with a number of contributions from the neighborhood. Luckily, that is precisely what has been taking place within the final years.
In the primary half of 2024, I’ve been in a position to work on this full-time. The migration is now about 50% full.

So, let’s shift gears!

How you may assist

  • You may take over a activity from the mission board! Or, you might familiarize your self with the talked about applied sciences / frameworks to make significant contributions later. In specific: Jetpack Compose / Compose Multiplatform. This may be very new to me too, so I’ve to search out my ft right here, too

  • You can sponsor growth! See the title “Sponsor this mission” within the sidebar on the principle web page. More cash permits me to commit extra time to growth on this app normally. If you recognize any eligible sources for bigger scale funding, discuss to me!

  • You may help with upkeep and subject triage normally. Time saved on that’s time I can put into furthering growth on this!



Source link