Chapter 10 Tutorial project - Data transformation in view controller

Hi @nservidio! There’s a post with a similar question to yours if you want to take a look: MVVM - Why are the businesses stored in the ViewController - #3 by jrg.developer

The short answer is yes, that data transformation could go into the view model and would make sense, but it’s also ok to have in the ViewController because the primary purpose of a viewmodel is to transform model information into values that can be displayed on a view and this code in particular is about images on the view.

1 Like