I feel like it\'s a fairly common paradigm to show/hide UIViews, most often UILabels, depending on business logic. My question is, what is the best
UIViews
UILabels
Try BoxView, it makes dynamic layout concise and readable. In your case it is:
boxView.optItems = [ firstLabel.boxed.useIf(isFirstLabelShown), secondLabel.boxed.useIf(isSecondLabelShown), button.boxed ]