---
title: "From broken to testable SwiftUI navigation: The decoupled approach of MVVM with coordinators"
url: https://daily.dev/posts/from-broken-to-testable-swiftui-navigation-the-decoupled-approach-of-mvvm-with-coordinators-z3it7tnej
source_url: https://matteomanferdini.com/mvvm-coordinator-swiftui/
type: article
source: "Matteo Manferdini"
published: 2025-12-16T11:00:22.597Z
updated: 2026-03-15T06:50:05.676Z
tags: ["general-programming", "ios", "swift", "swiftui", "testing"]
reading_time: 7
upvotes: 1
comments: 0
language: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# From broken to testable SwiftUI navigation: The decoupled approach of MVVM with coordinators

**[Matteo Manferdini](https://daily.dev/sources/matteomanferdini)** · 7 min read · 1 upvotes · 0 comments

## Summary

SwiftUI's built-in navigation tools work well for small apps but create architectural problems at scale, including scattered navigation logic, tight coupling between views, and untestable code. The coordinator pattern addresses these issues by centralizing navigation logic, removing coupling, enabling dependency injection into view models, supporting deep linking, and making navigation testable through unit tests. The article demonstrates how to integrate coordinators with MVVM in SwiftUI, showing practical examples of handling value-destination links, view-destination links, and deep link management.

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://matteomanferdini.com/mvvm-coordinator-swiftui/>

## Similar posts on daily.dev

- [The Coordinator Pattern for SwiftUI \(NavigationStack\)](https://daily.dev/posts/the-coordinator-pattern-for-swiftui-navigationstack--ilsttzfbz) · Medium · 0 upvotes · 0 comments
- [Unit Testing Navigation Logic in SwiftUI](https://daily.dev/posts/unit-testing-navigation-logic-in-swiftui-ejn2uk5mr) · AzamSharp · 0 upvotes · 0 comments
- [Why Dismissing View Models in SwiftUI is Stifling your App’s Maintainability and Testability \(And the Proven Principles for a Better Architecture\)](https://daily.dev/posts/why-dismissing-view-models-in-swiftui-is-stifling-your-app-s-maintainability-and-testability-and-th-nqz1dnx9x) · Matteo Manferdini · 0 upvotes · 0 comments

---

Tags: [#general-programming](https://daily.dev/tags/general-programming), [#ios](https://daily.dev/tags/ios), [#swift](https://daily.dev/tags/swift), [#swiftui](https://daily.dev/tags/swiftui), [#testing](https://daily.dev/tags/testing)

[View this post on daily.dev](https://daily.dev/posts/from-broken-to-testable-swiftui-navigation-the-decoupled-approach-of-mvvm-with-coordinators-z3it7tnej)
