By using this site, you agree to the Privacy Policy and Terms of Use.
Accept
World of SoftwareWorld of SoftwareWorld of Software
  • News
  • Software
  • Mobile
  • Computing
  • Gaming
  • Videos
  • More
    • Gadget
    • Web Stories
    • Trending
    • Press Release
Search
  • Privacy
  • Terms
  • Advertise
  • Contact
Copyright © All Rights Reserved. World of Software.
Reading: How Tripadvisor Migrated to The Composable Architecture for Their SwiftUI App
Share
Sign In
Notification Show More
Font ResizerAa
World of SoftwareWorld of Software
Font ResizerAa
  • Software
  • Mobile
  • Computing
  • Gadget
  • Gaming
  • Videos
Search
  • News
  • Software
  • Mobile
  • Computing
  • Gaming
  • Videos
  • More
    • Gadget
    • Web Stories
    • Trending
    • Press Release
Have an existing account? Sign In
Follow US
  • Privacy
  • Terms
  • Advertise
  • Contact
Copyright © All Rights Reserved. World of Software.
World of Software > News > How Tripadvisor Migrated to The Composable Architecture for Their SwiftUI App
News

How Tripadvisor Migrated to The Composable Architecture for Their SwiftUI App

News Room
Last updated: 2025/06/12 at 4:43 PM
News Room Published 12 June 2025
Share
SHARE

In a thourough article, Tripadvisor iOS principal engineer Ben Sarrazin described their journey toward adopting The Composable Architecture (TCA) for their existing iOS app, moving away from the Model-View-ViewModel-Coordinator (MVVM-C) architecture.

Sarrazin explains that the decision to move away from MVVM-C was driven by several factors, all tied to increasing app complexity and a growing team. One of the pain points was navigation:

Perhaps the most painful aspect of our MVVM-C implementation is the navigation structure — or more accurately, the lack of one. Our coordinators can launch any other coordinator, creating a web of navigation possibilities that is nearly impossible to document or reason about.

For example, this complexity became evident when an anonymous user visiting the site attempted an action requiring authentication. Even in such a common scenario, the MVVM-C navigation involved numerous coordinators, view models, and event mappers, making the codebase hard to understand and modify.

Another challenge stemmed from the coordinators’ reliance on UIViewControllers, which added complexity and required using Combine as a communication layer between SwiftUI and UIKit.

Debugging Combine-based event chains proves exceptionally difficult, especially when they traverse multiple coordinators and are composed of several layers of publishers and operators.

TCA, by contrast, promised several advantages, such as seamless integration with SwiftUI, robust testing capabilities, and improved composability. The Tripadvisor team also valued TCA’s evolution and maturity, along with its high-quality documentation and support.

To handle the migration, the Tripadvisor iOS team adopted a bottom-up approach. They began by identifying view models without children and replacing them with TCA stores, then gradually worked their way up to parent view models.

A similar “leaf-to-root” strategy was applied to navigation elements, but with a twist. In fact, since TCA requires centralized, state-driven navigation, coordinators were not replaced one-to-one. Instead, parent coordinators assumed the navigation responsibilities of their children. This ultimately resulted in a single source of truth for navigation: a global router implemented as a TCA reducer.

This navigation consolidation represents perhaps the most transformative aspect of our migration. Where we currently have dozens of coordinators with overlapping responsibilities and complex interactions, we’ll eventually have a clean, state-based navigation system that’s both more powerful and significantly easier to understand.

The migration required a complete mindset shift, explains Sarrazin, and came with some challenges. One key insight was that replicating the existing feature hierarchies in TCA wasn’t always the best approach. Instead, the team learned to take into account the implications of sending actions between parent and child components, which can lead to excessive bidirectional communication. A better pattern, they found, was to centralize shared behaviors in parent components where possible.

Another challenge arose when too many actions were dispatched in a short time span, for example, while scrolling through a list. To address this, the team found it effective to debounce high-frequency inputs and minimize the number of actions sent to the store, favoring simple state updates within reducers instead.

An area where TCA also brought many benefits was testing, helping reduce test brittleness.

We found that tests written with TCA’s TestStore provided much stronger guarantees about application behavior. A test that passes gives us high confidence that the feature works as expected, which wasn’t always true with our previous testing approach, especially with the heavy dependency on Combine and schedulers.

Additionally, the team found that TCA tests often served as a form of design feedback: when a test became hard to read or write, it was usually a sign that the underlying code could be improved.

Overall, the migration proved very effective, according to Sarrazin. His article offers many valuable insights that go beyond what can be covered here. Do not miss it if you’re interested in the full detail.

Sign Up For Daily Newsletter

Be keep up! Get the latest breaking news delivered straight to your inbox.
By signing up, you agree to our Terms of Use and acknowledge the data practices in our Privacy Policy. You may unsubscribe at any time.
Share This Article
Facebook Twitter Email Print
Share
What do you think?
Love0
Sad0
Happy0
Sleepy0
Angry0
Dead0
Wink0
Previous Article What Is Cross-Selling: Strategies, Benefits and Tools |
Next Article Cheap AI Tools May Come at a Bigger Long-Term Cost
Leave a comment

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Stay Connected

248.1k Like
69.1k Follow
134k Pin
54.3k Follow

Latest News

The High-Flying Escalation of CBP’s Predator Drone Flights Over LA
Gadget
Minnesota lawmakers approve social media mental health warning measure 
News
CBEX is back, and Nigerians are paying again despite frozen funds
Computing
MindsEye review – a dystopian future that plays like it’s from 2012
News

You Might also Like

News

Minnesota lawmakers approve social media mental health warning measure 

2 Min Read
News

MindsEye review – a dystopian future that plays like it’s from 2012

7 Min Read
News

This Android notification exploit could trick you into opening some very unfriendly links

4 Min Read
News

Massive $3.5m coin collection found in walls of mans home

4 Min Read
//

World of Software is your one-stop website for the latest tech news and updates, follow us now to get the news that matters to you.

Quick Link

  • Privacy Policy
  • Terms of use
  • Advertise
  • Contact

Topics

  • Computing
  • Software
  • Press Release
  • Trending

Sign Up for Our Newsletter

Subscribe to our newsletter to get our newest articles instantly!

World of SoftwareWorld of Software
Follow US
Copyright © All Rights Reserved. World of Software.
Welcome Back!

Sign in to your account

Lost your password?