Michael Long
Jan 25, 2023

--

If you're going to have a published array of class objects, then they too need to be observable objects.

And which is a fairly specific issue on which to justify the use of a single specific architecture.

And, frankly, it's the single overall computed state (similar to react) that biases me against TCA in SwiftUI. SwiftUI prefers a largely distributed state as opposed to one where each and every change to the global state requires SwiftUI to diff each and every view in the app for changes.

With localized state, a change in that state triggers an update cycle for the affected views only.

--

--

Michael Long
Michael Long

Written by Michael Long

I write about Apple, Swift, and SwiftUI in particular, and technology in general. I'm also a Lead iOS Engineer at InRhythm, a modern digital consulting firm.

Responses (1)