One demanding feed workload implemented in Swift, Kotlin, Dart, and TypeScript. The repository compares engineering trade-offs without pretending that one benchmark can select a platform for every product.
Every implementation performs the same work:
- Decode 1,200 feed records and 360 incremental updates.
- Resolve duplicates by version.
- Apply updates and tombstones.
- Sort by update time with a stable tie-breaker.
- Filter and paginate the result.
- Exercise an LRU image cache under a fixed byte budget.
- Produce the same deterministic checksum.
The benchmark reports latency, result size, page count, cache behavior, and checksum. Runtime numbers are useful only when collected on the same machine and build mode.
implementations/
ios-swift/ Swift 6 core and SwiftUI adapter
android-kotlin/ Kotlin/JVM core and Compose adapter
flutter-dart/ Dart core and Flutter adapter
react-native-typescript/ TypeScript core and React Native adapter
backend/ Dependency-free reference API
benchmark/ Cross-platform runner and report generator
shared/ Contract, fixture, scenarios, diagrams
docs/ Method and decision framework
./scripts/verify.shRun the comparative benchmark:
python3 benchmark/runner.pyRun the live API scenario:
./scripts/e2e.shIf Dart is not installed, local verification skips Dart and reports it clearly. GitHub Actions installs Dart and verifies all four implementations.
The same domain rules are intentionally implemented with native language idioms. Shared code is limited to contracts and fixtures. This exposes the real differences in concurrency, type systems, tooling, build pipelines, native integration, and operational cost.
See the decision framework for when each platform is a reasonable default and when it is not.
Generated output is written to benchmark/results/latest.json and benchmark/results/latest.md. Do not compare debug builds with release builds or measurements from different devices.
MIT