Why Conditional View Modifiers are a Bad Idea

When applied to a SwiftUI View, a ViewModifier produces a different version of the original value. To address the need to apply a modifier to a View only when a condition holds true, many developers implement some version of a conditional view modifier. In this post, Chris Eidhof explains why doing so is not a good idea.