Michael Long
Jul 16, 2023

--

Decent approach, but it presumes each section is homogenous in regard to cell type and you didn't eliminate the switch as it's embedded within the setup function.

Though to be fair, the article title said "avoid', not "eliminate".

Also in the future please use Medium's code editor as opposed to screenshots. The code editor is easier to read and the code examples can actually be copy/pasted.

--

--

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)