Migrating Doximity’s iOS Newsfeed to SwiftUI Without Disrupting Users or Development
Doximity migrated its server-driven iOS Newsfeed from UIKit to SwiftUI incrementally, using The Composable Architecture's separation of state from views as the migration boundary. First, individual sections were rewritten in SwiftUI and hosted in UITableView cells via UIHostingConfiguration. Then the bridge was reversed: a SwiftUI ScrollView/LazyVStack took over scrolling while the remaining UIKit sections were wrapped in UIViewRepresentable. The new feed was validated with unit, UI and manual tests, rolled out to a small percentage of users with rollback available, and measured with a programmatic scrolling benchmark reporting FPS, missed frames and p50/p95/p99 frame intervals.
Related posts
- Challenges of mixed SwiftUI and UIKit codebases in iOS Apps
Medium Engineering mediumAdeptMixing SwiftUI into Medium's 2013-era UIKit iOS app brings recurring friction: sizing SwiftUI views hosted in UIHostingController as table/collection cells, mismatched scroll APIs (offset sign differs), and duplicated components like PostPreview implemented in both frameworks. Medium keeps UIKit for app-wide navigation and SwiftUI for local feature navigation, avoids SwiftUI TextField due to focus limitations, and notes weaker SwiftUI view debugging. A scroll performance issue from wrapping UILabel with NSAttributedString in a SwiftUI list was fixed by switching to native Text with AttributedString; raising the minimum target from iOS 13 to 16 reduced version-specific code.
- How we build SwiftUI features in the Medium application
Medium Engineering mediumAdeptMedium's iOS team builds new iOS 13+ features in SwiftUI and Combine by splitting a monolithic, partly Objective-C codebase into Swift packages: ApolloModel for generated GraphQL models, SharedUI components, per-feature UI packages, and planned LiveService/FakeService packages. Network services are structs returning Combine publishers, with live and fake implementations injected through initializers in a style inspired by Point-Free, rather than being registered in a global service registry. Views take protocol-backed GraphQL fragments so previews and tests can use simple structs, and enum action handlers forward events to custom UIHostingControllers for app-level navigation. Building packages in isolation makes SwiftUI previews fast, though List, NavigationView and Menu still have gaps that require OS-version workarounds.
- Lessons From Building iOS Widgets
Shopify Engineering mediumAdeptShopify rebuilt its iOS analytics widgets natively in SwiftUI rather than React Native, because app extensions have tight memory limits, WidgetKit serializes SwiftUI view hierarchies, and React Native had no official widget support. Each widget fetches data independently through Reportify/ShopifyQL while sharing session tokens with the app. iOS calls getTimeline and getSnapshot several times per update cycle, which caused redundant network calls and a token-refresh race that logged users out. A one-minute per-widget cache keyed on configuration fixed both problems. The post also covers a flexible metric decoder, a size-agnostic SwiftUI layout built on LazyVGrid and an OptionSet of layout options, and why relative timestamps were rejected for lack of customization.
- How we brought Datadog’s data visualization to iOS: A focus on performance
Datadog Engineering mediumAdeptDatadog built DogGraphs, an internal SwiftUI graphing library constrained to iOS 14 (no Canvas), with a result-builder API that type-checks graph compositions at compile time. Profiling with _printChanges() and Xcode Instruments showed that layers observing a shared EnvironmentObject coordinate system caused twice the expected body evaluations (339 vs 113 for a 113-line chart). Moving coordinate-system reduction into the @resultBuilder via TupleGraphContent fixed that. For charts with thousands of bars, a Batch content type groups shapes by fill and stroke style and draws each group as a single Path, which removes the rendering hangs. The post also explains SwiftUI's diffing order: memcmp for POD views, then Equatable, then reflection.
- Custom Navigational Transitions in iOS
Zalando Engineering mediumAdeptZalando's iOS app adds a custom zoom-style push transition between backend-driven screens. The tapped outfit card grows into the details view, built on UIKit's UIViewControllerAnimatedTransitioning and a custom navigation delegate. Because the backend-defined UI and the generic deep-link router lack context about the tapped view, the team intercepts the tap to capture its frame and snapshot and passes them through the navigation service. Plain drawHierarchy snapshots pixelated and scaled text badly, so they switched to recursively re-rendering the tapped layout per component, omitting labels and buttons and rendering real image views, which gave crisp transitions reusable across screens.