Imagining an Xcode autocomplete picker that lists SwiftUI modifiers according to their “impact” on the elements in the view hierarchy. Nearly every modifier modifies a View and returns a View but they often are intended for a specific family of controls. So if there’s a ScrollView in the hierarchy, it’ll surface things like contentMargins. If there’s a Button, you’ll get buttonStyle and buttonShape.

@mattcomi This would require language facilities to model the relationships and then support in the completion result system.

But I really like the concept! And I think a language extension like this seems cool!

@mattiem at the very least the documentation would need to be annotated to indicate a modifier’s associated views. Traversing the hierarchy is another, much bigger problem.