Oct 27, 2024
First approach, that of storing the viewbuilder and not the view, is not recommended.
The following article explains the pitfalls, but it basically works against SwiftUI's optimizations and against the diffing mechanisms used to determine view redraws.