Michael Long
Sep 10, 2023

--

If the view requires a view model (not all do), then the view that needs it creates it.

I'm fighting a battle at the moment where I work as people tend to want to create VMs externally and pass them into the view as needed, but that increases call site complexity and tends to "freeze" the view's internals, making further composition difficult, if not impossible.

Glad you liked the article!

--

--

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.

No responses yet